Thank you, Christopher. Unfortunatley, I'm not working with the same data types. I need to go into a FeatureClass from either a geodatabase table or a layer (.lyr) file.
# Open a search cursor on a feature class / table to read from scur = arcpy.SearchCursor(read_fc) # Open an insert cursor on the fc / table to write to icur = arcpy.InsertCursor(write_fc) for srow in scur: irow = icur.newRow() irow.shape = srow.shape irow.setValue(to_field1, srow.getValue(from_field1)) irow.setValue(to_field2, srow.getValue(from_field2)) icur.insertRow(irow) del irow, icur, srow, scur
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.