Nipun
Nipun

Reputation: 4319

sync database between wp8 app and server

I am creating a WP8 App. I have a created a sqlite database in the isolated storage.

Now my data keeps updating and I want to regularly download the latest data from the server database and update the local database.

The database in the WP8 cannot be changed at the client side so there will be only 1 side data merging.

Which is the best way and service to use?

Upvotes: 3

Views: 327

Answers (1)

Deathspike
Deathspike

Reputation: 8770

If you do not work with a large database, you might prefer to replace the device database and not worry about merging. This can be as simple as making an export of the server database, transferring it to the device and then importing it into the device database. The appropriate method of dumping the database on the server side is dependent on the type of database (e.g. mysqldump in the case of MySQL).


If you do work with a large database, or if you are struggling with bandwidth issues on the device, you might want to use a technique to detect differences. One of the easiest methods is change tracking on the database. All modifications can then be logged with an change_at timestamp. The device can then remember which is the last modification it contains, get the new entries, and replicate the changes locally (For in-depth detailed explanation, please provide more information of the server environment and data structure).

Upvotes: 1

Related Questions