Hi , I am trying to use CopyFeatures_management function in ArcGIS 10 using python script and its working too slow. My dataset which it is copying is around 1 GB in size. It is taking 2 days to copy features to finish. Everything works fine like merging , joining ..but the problem is with CopyFeatures_management function. Here's my sample code for the join process.def processJoin(lyr):
# Join logistics tables to network fc
gp.AddMessage("Joining lrs table...")
logFile.write("Joining lrs table...\n")
gp.AddJoin_management(lyr, JOIN_FLD, lrs, JOIN_FLD)
gp.AddMessage("Joining ltr table...")
logFile.write("Joining ltr table...\n")
gp.AddJoin_management(lyr, tempFC + "." + JOIN_FLD, ltr, JOIN_FLD)
# Copy layer to fc
gp.AddMessage("Copying features to feature class...")
logFile.write("Copying features to feature class...\n")
gp.CopyFeatures_management(lyr, ExportRoadnetwork)
As you can see from the code, we are just calling CopyFeatures_management to make a copy of the newly joined feature class. But its taking 2 days to finish. Size of the joined dataset is around 1 GB for state data of DC,VA,PA,DE,MD and NJ. We are only using *.*nw data with lrs and ltr for restrictions. Although merge is just taking 20-25 minutes , copying the features is itself taking too long to complete. Can anybody please provide some suggestions where I am doing wrong or how can I improve performance in the script.