Can anyone get the release version of a ESRI local geodatabase, using arcpy? I should be simple, and yet...
I use the "Describe" function on both personal and file geodatabases, and need to retrieve the workspace properties "release" or "currentRelease" - either would do: I want to pinpoint databases that need upgrading (this project is run in ArcGIS 10.0, I am looking for 9.x databases.)
I based the code below on the properties exposed in the ESRI help (here):
import arcpy, os, sys data = r"C:\NEW_GDB.gdb" desc_gdb = arcpy.Describe(data) if hasattr(desc_gdb,"workspaceType"): print desc_gdb.workspaceType print desc_gdb.workspaceFactoryProgID else: print "no 'workspaceType' property" if hasattr(desc_gdb, "release"): print desc_gdb.release else: print "\nno 'release' property" if hasattr(desc_gdb, "currentRelease"): print desc_gdb.currentRelease else: print "no 'currentRelease' property"And here is the result I get:
>>> LocalDatabase esriDataSourcesGDB.FileGDBWorkspaceFactory.1 no 'release' property no 'currentRelease' property >>> Any help or advice appreciated! Many thanks!!
Hélène.
أكثر...
I use the "Describe" function on both personal and file geodatabases, and need to retrieve the workspace properties "release" or "currentRelease" - either would do: I want to pinpoint databases that need upgrading (this project is run in ArcGIS 10.0, I am looking for 9.x databases.)
I based the code below on the properties exposed in the ESRI help (here):
import arcpy, os, sys data = r"C:\NEW_GDB.gdb" desc_gdb = arcpy.Describe(data) if hasattr(desc_gdb,"workspaceType"): print desc_gdb.workspaceType print desc_gdb.workspaceFactoryProgID else: print "no 'workspaceType' property" if hasattr(desc_gdb, "release"): print desc_gdb.release else: print "\nno 'release' property" if hasattr(desc_gdb, "currentRelease"): print desc_gdb.currentRelease else: print "no 'currentRelease' property"And here is the result I get:
>>> LocalDatabase esriDataSourcesGDB.FileGDBWorkspaceFactory.1 no 'release' property no 'currentRelease' property >>> Any help or advice appreciated! Many thanks!!
Hélène.
أكثر...