Sample Applications for Peer-to-Peer Synchronization

The Sync Services for ADO.NET 2.0 documentation contains complete applications for peer-to-peer synchronization in the how-to topics. For more information, see Programming Common Peer-to-Peer Synchronization Tasks. The following sample applications are installed by the Sync Framework SDK. The Sync Framework SDK is available at this Microsoft Web site.

  • SharingAppDemo-DecoupledTracking

  • SharingAppDemo-CoupledTracking

  • SharingAppDemo-Conflicts

  • SharingAppDemo-ColumnMapping

  • SharingAppDemo-TombstoneCleanup

All the applications contain similar application code and have a similar graphical interface. The applications allow you to connect to three peer databases, make changes in those databases, and then synchronize the changes. Each application focuses on a different aspect of synchronization, such as decoupled change tracking or conflict handling.

To use each sample application

  1. Open the setup directory for the sample that you want to run, for example SharingAppDemo-Conflicts\setup.

  2. In SQL Server Management Studio, execute peer1_setup.sql and then peer1_procs.sql. This creates a database and tables, and a set of stored procedures that Sync Services uses to select and apply changes to each peer. Repeat this step for the peer2 and peer3 scripts.

  3. In SQL Server Management Studio, open demo.sql and execute the Configure Scope Members section at the top of the script.

  4. In Visual Studio, open the solution, such as SharingAppDemo-Conflicts.sln.

  5. Build and run the project.

  6. Make data changes and synchronize the peers.

See Also

Concepts

Collaboration Scenarios (Sync Services)