I'm taking an old application and creating an entire new version. I'm going to use SQL Server for the local and a remote Database(s). In order to allow the local and remote databases to stay in sync I'm going to write a sync process...
May use Microsoft Sync Framework or something custom... that is a question for later.
The current version of the Database uses int Primary Key values with Auto Increment. Bad news for keeping changes in sync because of the possibility of PK duplicates.
In order to get around this I see two basic options:
1) Create a new PK based on the int ID value + the source (like "local" or "remote_db_name")
2) Switch the PK to GUID
I see negatives in both, but I'm leaning towards GUID ... which means a painful data conversion with lots o scripts, plus possible slow index issues...
After reading this post I'm wondering if I should do some sort of combo, like using the GUID for the sync, but the "combo key" for everything else? That might be a waste though....
Am I missing alternative approaches?
Thanks!