Merge multiple files using the batch-type ArcPython geographic database (* .gdb) or in ArcGIS personal geodatabase (* .mdb)
Usage scenarios: one in which the need to merge together in more than 100 cities and counties cadastral database, eventually finishing as the final data remitted,
Open the ArcMap Python window, copy the code above (note to put the path into your own), Enter to start implementation of
code show as below:
SYS Import
Import ArcPy
Import String
the try:
Workspace = '100 MDB stored in the plurality of paths'
outdb = 'C: \ the Users \ Administrator \ Desktop \\ total output database .mdb'
arcpy.env.workspace outdb =
FS = ArcPy. ListFeatureClasses ()
arcpy.env.workspace = Workspace
for File in arcpy.ListFiles ( "* * db."):
for f in FS:
arcpy.Append_management (File + "\\" + f, outdb + "\\" + f)
except arcpy.ExecuteError:
print arcpy.GetMessages()