mssql data synchronization three cases

First, the principle is synchronized by copying MSSQL own principles, but its function is really very powerful

that it has three copy function, I simply explain:

1. snapshot publication. Simply put, it is to require a certain time to synchronize with the main database server is about speed, but can not do real-time synchronization.
2. transactional publication can do real-time synchronization of data, but can only access the primary database server, database server and other synchronization to synchronize with the main database server, how should I say, the data is a modification of the primary database server, database server deputy update, if the primary server is broken, then the deputy database server can not provide the service, simply means that the backup database does not provide access to the database
3. merge publication. I feel more considered the strongest, assuming that two database servers, No matter what stage you access the database server, which means that as long as the database table has any changes, then these two will sync immediately, of course, this requires a lot of bandwidth, so this time I plan, two servers are connected to 1000MB, data basically the same.

I also used to resolve merge distribution MSSQL database synchronization problems.

let's take a building you want to synchronize database BBSXP-a of a database server, database BBSXP-B of B database server

open the database business management device, the database servers a and B are registered in the manager
opens a database selection System, open the sub-column, post content selection, right-click the new hair-step, out of the Create Publication Wizard dialog box
shown in Figure 1:

Then went the next step, select the desired synchronization of databases, after completing select the database, we must choose the type you want to copy, that can replicate the type explained above, according to their needs to be, where I chose to merge affairs. Then select the type of subscriber, here select the default SQL2000, then is to choose to synchronize the database table. I usually select all, of course, if just a table, select a table as long as you can. here to explain, because the transactional publication the principle reads the database and processing, so if you choose a transactional publication, it may lead to some tables can not be used as a synchronization object. then select "add a unique identifier identity column in the table"
and then continue to the next step, follow the prompts until the last Next

publisher so done, is doing and then synchronize the database server subscriber.

Subscriber other is also very simple, subscription options, select New server, and then follow the prompts to follow suit.

when two servers do all after completion, then down a more crucial step

in publishing and subscription service Is done only after, to copy monitors - Select the published server - the publisher

before the synchronization, no matter what type of release, should be in Figure 2, a snapshot, the sync can begin

to write so much, too I do not know there is no mistake, if you have any questions, we discuss can also see help for MSSQL, which written in more detail, but also various types of published works, I am not here to say -

this experiment I It has been done, and now has been put into the project application, and hope that we can continue to discuss issues related to ~

Guess you like

Origin www.cnblogs.com/SyncNavigator8-4-1/p/10977500.html