I have a script to insert rows into the table which is versioned. I added the table to my map project and changed it to my version. However, the SDE connection file is set to the default version and I used this connection file as the workspace for the editor object's startEdition method. When I ran my script, I got this error message: workspace already in transaction mode. Then I switched my connection to my edit version so the table in my map project and connection file all point to the same version. My script worked. The new rows were inserted successfully.
My question is: is there a way that I can set up the workspace to point to my editing version in the code? My users change versions during the daily work and it is really a problem if they have to create a lot of connection files that point to different versions. I have searched and I did not find any useful info.
Thanks
I may miss something. The change version geoprocessing tool only changes the version of a layer or table. It is not for a workspace.
Thanks