Best .NET3.5 based strategy for creating disconnected db application

后端 未结 5 481
傲寒
傲寒 2021-02-03 13:52

My requirements are:

  • Relatively small database: 25-30 tables with 4-5k rows in each.
  • 4-5 users with their own copies of local database on their laptops. Sync when
  • 相关标签:
    5条回答
    • 2021-02-03 14:18

      To the OP:

      The one word of warning I will give you on the Sync framework front is upgrading a database schema throughout the versions. I'm using it on a project that I'm developing now, and am starting the "2.0" specification, which I've decided to remove it for various reasons.

      I would greatly suggest you take the time to thing through the idea of how you wish to handle schema changes as you progress, and decide if this is the way that you want to go. For me, it was to get the system up and running, but now that I'm dealing with the nightmare, I'm falling victim to the NIH scenario.

      My outlook for 2.0 is to continue to use SqlCE for the clients, and SQL Server 2008 for the COR... but to roll my own Sync Fx based on heavy usage of reflection and a set of "DTO" objects.

      0 讨论(0)
    • 2021-02-03 14:22

      If there is a SQL Server (Standard or higher) already in place, you can use SQL Server Replication Services to sync local copies of the database to either a SQL Express or SQL Server Compact instance on the user's machine (both of these are free).

      For more information, try here.

      It sounds like you'd be looking at Merge replication scenario.

      0 讨论(0)
    • 2021-02-03 14:24

      Microsoft has a pattern for this they call Occasionally Connected Client.

      0 讨论(0)
    • 2021-02-03 14:26

      Have a look at the Microsoft Sync Framework.

      Introducing the Microsoft Sync Framework – a comprehensive synchronization platform enabling collaboration and offline for applications, services and devices with support for any data type, any data store, any transfer protocol, and network topology.

      0 讨论(0)
    • 2021-02-03 14:27

      Add -> New -> "Local Database Cache". This should provide all the sync you need (via ADO.NET Sync Framework), running (IIRC) by SQL CE by default, which is (I believe) free.

      0 讨论(0)
    提交回复
    热议问题