copy/paste selected feature from one fc to another, with both fc in versioned GDB

450
2
06-22-2011 11:15 AM
ShannonLadd
New Contributor
Hi,

I am trying to take a feature that I have selected, copy that feature, and paste it into another feature class. Both feature classes are within the same versioned SDE GDB.

I have looked into using the Copy (Data Management) and Append (Data Management) tools, but the Copy tool creates an output, which I don't want, and the Append tool will not work within an edit session due to locks on the feature classes being used and will not work outside of an edit session because it will not append to the versioned data.

I was wondering if there is any code that will replicate manually using the copy (Ctrl+C) and paste (Ctrl+V) to achieve this?

Regards,

Shannon
Tags (2)
0 Kudos
2 Replies
MathewCoyle
Frequent Contributor
Append should work... I've never tried it within a script while editing, but it does work on versioned data that is being edited.
0 Kudos
JakeSkinner
Esri Esteemed Contributor
The append should work inside or outside an edit session.  If you perform the append outside of an edit session, make sure the 'Connection Details' within the connection properties of the geodatabase are set to the version you wish to update.
0 Kudos