Is this possible or do you have to delete one cursor before opening another?
RuntimeError: workspace already in transaction mode
with arcpy.da.InsertCursor('Points_Geom', ["PointID", 'SHAPE@XY']) as cursor: cursor.insertRow((123458, (4364181.91, 263840.13)))
cursor = arcpy.da.InsertCursor('Points_Geom', ["PointID", 'SHAPE@XY']) cursor.insertRow((123458, (4364181.91, 263840.13))) del cursor
import arcpy edit = arcpy.da.Editor(r'C:/Projects/GISPROD_ElectricDistribution_Extract.gdb') edit.startEditing(False,False) theIC = arcpy.da.InsertCursor(r'C:/Projects/GISPROD_ElectricDistribution_Extract.gdb/electric/servicepoint',['PHASEDESIGNATION', 'WORKORDERID', 'SUBTYPECD', 'PLACEMENTCONFIDENCE', 'SHAPE@']) theIC.insertRow(['7', '280773', '1', '90', arcpy.Point(292840.72313, 4818098.69548)]) edit.stopEditing(False)
Angemeldete Mitglieder können Beiträge verfassen, Updates folgen und mehr. Neu hier? Registriere ein kostenloses Konto.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.