saving feature layer using globalid

676
1
03-14-2013 08:31 AM
JeffRogholt
New Contributor II
Is there a way to save an ArcSDE feature item using the globalid rather than the objectid?  If you want the details of the scenario continue reading otherwise skip to 2) below.

We have a load balanced environment so our servers, database and application are duplicated on 2 servers.  Users will be adding features on server 1 and server 2.  These features need to be available on both servers so we are using the Microsoft Sync Framework to sync the feature class tables. 

We're running into 2 problems:
1) Objectid's can be reused after being deleted.  Ex:
Create a feature and it's assigned objectid 1000 on server 1. 
Run the sync process to add objectid 1000 to server 2.
Delete objectid 1000 and sync so it's removed from both tables.
Since objectid's are reused (they're not sequential) objectid 1000 might/will be reused and when it is reused it will not sync with the other table because it's in the change tracking table as being deleted when it was used the first time.

2) To avoid the problem in #1, I changed the primary key from objectid to globalid to make the sync framework work properly.  Now I have 2 different features in the table with the same objectid.  When I edit one, the other also gets updated.  Is it possible to save, delete, etc. based on globalid rather than objectid?

I hope I explained this well enough.  Thanks.


-Jeff
0 Kudos
1 Reply
JeffRogholt
New Contributor II
I dug further into the Sync Framework and it's possible to clean up the delete entries of the _tracking table so I no longer need to use the GlobalID's.  Thanks.
0 Kudos