I need to copy over feature classes from another entities SDE. The user account I am using is allowed to see feature classes, but not the related tables. Therefore most methods are out for copying data.
What I am doing is writing a script to copy over the data into a file geodatabase. What i am running into is:
"WARNING: Failed to convert: {insert feature class here} ERROR 999999: Error executing function. Insufficient permissions {insert feature class's related table(s)}.
WARNING: Failed to convert: Database Connections\Utilities.sde\Utilities.GIS.ElectricUtility\Utilities.GIS.Switchgear. ERROR 999999: Error executing function.
Insufficient permissions [Insufficient permissions[Utilities.GIS.UndergroundDistributionInspection]]
Failed to execute (CopyFeatures).
It fails then to bring over that feature class with a related table into the file geodatabase. Is there a way around the permissions issue?
import arcpy
try:
arcpy.env.workspace = r"Database Connections\Utilities.sde\Utilities.GIS.ElectricUtility"
muE = arcpy.ListFeatureClasses(feature_type='point')
print(muE)
for muEFS in arcpy.ListFeatureClasses(feature_type='point'):
arcpy.FeatureClassToGeodatabase_conversion(muEFS, r"Z:\MXDs\Services\Utilities_EF.gdb")
except:
pass
I should also add - "Besides having them change the permissions to the tables."
Update: arcpy.FeatureClassToGeodatabase does not work either, used as a code snippet direct from ArcGIS Desktop. However, using an import multiple feature class works by right clicking on the file geodatabase. Riddle me that one, Batman?