I'm trying to write a python script to load feature class from an existing geodatabase to a new one, here is my script:
import arcpy
from arcpy import env
import os
import traceback
#Set up workspace
outworkspace = r"C:\user\Geodatabases\Gdb_mena_v3.gdb"
workspace = r"C:\user\Geodatabases\gdb_4.3.0_v2.gdb"
arcpy.env.workspace = workspace
#get a list of feature classes
featureclasses = arcpy.ListFeatureClasses()
for fc in featureclasses:
shp_file = fc
if shp_file == "MAP":
arcpy.Append_management(os.path.join(workspace, shp_file), "C:\\user\\Geodatabases\\Gdb_mena_v3.gdb\\MAP", "NO_TEST", "","")
print('Your load is done')
else: print('Error reading data')
print "Finished!"
when I run the script I get this message:
Error reading data
Error reading data
Error reading data
Error reading data
Error reading data
Your load is done
Error reading data
Error shape file did not get read
Finished!
Note that in my first geodatabase I have 7 features classes