The Create Synchronization Model Wizard takes you through the steps of setting up synchronization between the consolidated database and remote database.
To create a synchronization model
Start Sybase Central.
From the Tools menu, choose MobiLink 11 » Set Up MobiLink Synchronization.
The Create Synchronization Model Wizard appears.
Type sync_ase as the name and type the location of your new model.
On the Primary Key Requirements page, select all three checkboxes. (You guarantee unique primary keys in Lesson 2.)
On the Consolidated Database Schema page, connect to the consolidated database:
The Connect To Consolidated Database window appears.
If you see an error message, ensure that the data source is configured properly.
Create a remote schema:
Choose and configure the download type:
Choosing timestamp-based downloads minimizes the amount of data that is transferred because only data that has been updated since the last download is transmitted.
Using shadow tables is often preferred because it does not require any changes to existing tables.
On the Download Deletes page, specify how to propagate record deletions to remote devices:
MobiLink creates shadow tables on the consolidated database to implement deletions.
On the Download Subset page, specify that the remote database should download only a subset of data from the consolidated database:
On the Upload Conflict Detection page, select No Conflict Detection.
Many applications require conflict detection, but this tutorial uses no conflict detection.
On the Publication, Script Version and Description page, type sync_ase_publication as your publication and type sync_ase_scriptversion as your script version.
The publication is the object on the remote database that specifies what data is synchronized. MobiLink server scripts define how uploaded data from remotes should be applied to the consolidated database, and script versions group scripts. You can use different script versions for different applications, allowing you to maintain a single MobiLink server while synchronizing different applications.
Click Finish.
Your model appears in Model mode.
"dbo"."stores"."stor_id" = {ml s.remote_id} |
The download cursor script specifies what columns and rows are downloaded from each table to the remote database. The search condition ensures that you only download information about one store, namely, the store that has an identifier that equals the remote ID for the database.
The synchronization model is complete and ready to be deployed.
Send feedback about this page via email or DocCommentXchange | Copyright © 2008, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.0 |