AnsweredAssumed Answered

Copying a Point Shape@ from a SearchCursor to a InsertCursor

Question asked by dougbrowning on Apr 11, 2018
Latest reply on Apr 16, 2018 by dougbrowning

I am trying to copy a Point from a SearchCursor to a InsertCursor but I can never get the geometry to work.  In past projects I ended up giving up on it and just did a Append then insert to get around it but I want to figure it out (unless this is a good way?).


First note that the Search FC and the Insert FC are different projections.  It may be that arc will not handle this for me.


This is like what I am trying (mini version) but it gives a AttributeError: __exit__


    fields = [ 'SHAPE@']
    with arcpy.da.SearchCursor(plotLayer, fields) as cursor:
        for row in cursor:

            saveShape = row[0]



   insertFields = [ 'SHAPE@']

    with arcpy.InsertCursor(terraFC, insertFields) as inCursor:


I have also tried SHAPE@XY and still no.  It seems like I have found code like this that works for Polygons but not points. Almost all examples of Point always use a x,y.


Thanks a lot for any help