Version: 10.2.1c and 10.2.1c SP3 |
ArcFM Desktop > Designer > Basic Designer Configuration > DesignID Index |
To maximize performance, you will want to add indices to the DesignID field of all feature and object classes that participate in a design. You will also need to update your Adds tables if working with a versioned geodatabase. You can run the following Python script to programmatically create the necessary indices:
import arcpy arcpy.env.workspace = r"c:\location_of_your_database\database_name.gdb" """ For a versioned database, point to the .sde file in your C:\Users\[username]\AppData\Roaming\ESRI\Desktop10.1\ArcCatalog directory. Be sure to have that connection use saved credentials. See http://gis.stackexchange.com/questions/16859/define-workspace-for-sde-connection-in-python for an example. """ for dataset in arcpy.ListDatasets(): for fc in arcpy.ListFeatureClasses(feature_dataset=dataset): try: arcpy.AddIndex_management(dataset + "/" + fc, "DesignID", "DesignID") except RuntimeError: print("Skipping feature class " + fc + " in dataset " + dataset) for table in arcpy.ListTables(): try: arcpy.AddIndex_management(table, "DesignID", "DesignID") except RuntimeError: print("Skipping table " + table)
Running the Script in ArcCatalog