Generate Licensed File Geodatabase (Data Management)

Summary

Generates a license definition file (.licdef) that defines and restricts the display of contents in a file geodatabase. The contents of the licensed file geodatabase can be viewed by creating a license file (*.sdlic) and configuring the ArcGIS clients to recognize it. The license file is created using the Generate File Geodatabase License tool.

Usage

  • Licensing is ideally suited to mature datasets that will be shared or licensed under a use agreement and do not require further editing. The output licensed file geodatabase cannot be unlicensed to return it to its original unlicensed format.

  • Once licensed, the output file geodatabase’s contents cannot be displayed in ArcGIS Pro until you create a license file (.sdlic) using the Generate File Geodatabase License tool and apply the license to each ArcGIS client.

  • You cannot license individual feature classes or tables to produce a mixed state in which some feature classes or tables are licensed and others are not. However, a licensed file geodatabase allows you to add an unlicensed feature class or table through operations such as creating a new, empty feature class, copying and pasting, or importing a feature class.

Parameters

LabelExplanationData Type
Input File Geodatabase

The unlicensed file geodatabase that will be licensed.

Workspace
Output Licensed File Geodatabase

The name and location of the generated licensed file geodatabase.

Workspace
Output License Definition File

The license definition file.

File

arcpy.management.GenerateLicensedFgdb(in_fgdb, out_fgdb, out_lic_def)
NameExplanationData Type
in_fgdb

The unlicensed file geodatabase that will be licensed.

Workspace
out_fgdb

The name and location of the generated licensed file geodatabase.

Workspace
out_lic_def

The license definition file.

File

Code sample

GenerateLicensedFgdb example 1 (Python window)

The following example demonstrates how to use the GenerateLicensedFgdb function in the Python window.

import arcpy
arcpy.env.workspace = "C:/data/"
arcpy.management.GenerateFgdbLicense("london.gdb", "london_lic.gdb", "london.licdef")
GenerateLicensedFgdb example 2 (stand-alone script)

The following example demonstrates how to use the GenerateLicensedFgdb function in a stand-alone Python script.

# Name: GenerateLicensedFileGeodatabase.py
# Description: Use the GenerateLicensedFgdb tool to license a file geodatabase

# import system modules
import arcpy

# Set environment settings
arcpy.env.workspace = "C:/data"

# Set local variables
geodatabase = "london.gdb"
out_geodatabase = "london_lic.gdb"
licdef = "london.licdef"

# Process: Restrict the data
arcpy.management.GenerateFgdbLicense(geodatabase, out_geodatabase, licdef)

Environments

Related topics