Click here to Skip to main content
15,671,266 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Please I have a c# winform application with SQL compact edition database deployed with my app. This application is installed on serveral computers.
What I am trying to do is that the SQL CE should be used as a standalone storage for the the client application pending when their is network connection (LAN) after which it should be synchronize to the central SQL server.
Please any help on this will be greatly appreciated

EDIT: I want the client system to download from the central database what other client update and also write to the central database

Why I want this : 1) To make my application work independently and also on a network

2) To increase Performance of application, just as mobile application uses sqllite to store their data on user phone ,after which sends to the server when internet is available

Thank you for your assistance

What I have tried:

We tried to retrieve the data from SQL CE to datatable then insert to sql server , but I don't know if it's a best practice
Updated 11-Feb-23 4:36am
PIEBALDconsult 11-Feb-23 9:48am    
I don't think you will find a general solution. It really depends on the actual needs of the application.
When you say "synchronize" I assume you mean that the client system will download changes made to the central database by other clients -- that makes things tricky.
If that isn't the case -- if the client simply needs to write to the central database -- then things are much easier.
You can use the "Improve question" button to add more details about what the challenge is.
Ese Ochuko 11-Feb-23 10:38am    
I want it to write And also read from from the central database
PIEBALDconsult 11-Feb-23 10:59am    
Such that each client receives updates from all other clients?
It can be done, you just have to bake that into the process.
Mainly you will need to track the changes (deltas) which the other clients will need.
I recommend not simply writing raw records to the central database.
It's best if you think in terms of transactions against the database, and send transactions, which the other clients can then download and apply to their local copies.
Gerry Schmitz 11-Feb-23 13:12pm    
You need to establish how much data is moving around and the operating hours before all else. The more data to sync, the smaller the window, the more complex the solution.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900