问题
When I provision a scope for synchronization in an SQL 2008 database like this:
SqlSyncScopeProvisioning sqlServerProv = new SqlSyncScopeProvisioning(sqlServerConn, myScope);
if (!sqlServerProv.ScopeExists(scopeName))
{
sqlServerProv.Apply(); // Apply the scope provisioning.
}
i see a bunch of change tracking tables, stored procedures and triggers created. Why is this not using the "Change Tracking" feature of SQL 2008, which is much cleaner and everything gets tracked behind the scenes? I thought that the "Change Tracking" feature of SQL 2008 was designed precisely to simplify these scenarios.
Now turning the question around: Is there a way to do a 2-way synchronization between two SQL Server 2008 databases just using Change Tracking in both of them instead of provisioning the triggers/auxiliary tables ?
回答1:
See Syncing SQL Server 2008 Databases over HTTP using WCF & Sync Framework
来源:https://stackoverflow.com/questions/5072065/microsoft-sync-framework-2-1-change-tracking-in-sql-server-2008