I have a destination (Feature Class):
I have a database table in the same file geodatabase that contains my source point data. I have columns with attributes in addition to the requisite coordinate data.
Using Arcpy, how do I retrieve the points from the source database table and create points in the destination Feature Class?
I tried creating a single point using this code:
import arcpy cur = arcpy.InsertCursor(fc, ["SHAPE@XY"]) pnt = arcpy.Point() pnt.x = 20000 pnt.y = 10000 feat = cur.newRow() feat.shape = pnt cur.insertRow(feat) del cur
but, although a row is created, the coordinates are 0,0.
Current thoughts - I'll probably use a cursor to step through the records retrieved and for each row in the source, build a point and insert it into the destination. The logic seems to make sense.