I have a C# Windows Forms application (writen in Visual Studio 2013) and I have the same database schema in both SQL Server (for master user) and in SQL Server Express (for clients). My database size is around 2 GB for each client.
I want to synchronize this databases once in a day or when needed. In SQL Server 2008, we have used RMO, but that API has been deprecated with SQL Server 2012.
I have tried using Merge Replication using T-SQL and able to create publication, add articles to publication, create subscriber and also able to register subscriber to publication but data was not synchronized.
Is there any good example for this(merge replication) which will work for SQL Server 2014 or later version then please suggest it.
Thanks.!
This is by no means a comprehensive answer, but it'll give you some pointers which you will then be able to research independently.
Here is how I do merge replication with anonymous pull subscribers:
sp_addmergepullsubscription
to create an anonymous pull subscription on the newly created subscriber databaseThe above roughly describes the process where the subscriber can connect directly to the SQL Server distributor instance. If you are planning on using Web Synchronization to connect to the distributor, that is an even wilder beast to tame (especially with IIS 7 or above), and I will leave that for another time.