July 7, 2009 at 10:50 pm
Hi
i have done merge replication in sql servers databases both are in sql server 2000. While creating the push subscription i do the following option for "Set Merge AgentSchedule " as "Continuously - privides minimum latency between when an action occurs at the publisher and is propagates to the Subscriber" . And for "Set subscription priority " i do follow the option " Use the following priority , between zero[lowest] and 99.99[highest] to resolve the conflict. I set the priority values 75/50 and tested.".
What i am facing is if add a record to the publisher database and after that if i add a record to subscriber, the record in the subscriber will be overwritten with the publisher record. The record in the subscriber will be deleted. I don't know much more in replication because first time i am doing this. Please do a help to solve this.....
July 8, 2009 at 12:06 am
If you are entering same records in both publisher and subscriber, the record originating from the publisher takes precedence over the one originating from the subscriber by the conflict resolver and hence only one is allowed to be synchronized to all nodes.
July 8, 2009 at 12:24 am
i will explain my requirement. In my database there is table to keep the player names. The table structure is
name : tblPlayers
fields:
ID(pk,int)- This field will be auto incremented by 1
Name:varchar 50
if i execute the query
Insert into tblPlayers(Name) values ('Sachin')
will create the ercord in tblPlayers like
ID Name
1 Sachin
After this if i add another record in the subcriber using the following query
Insert into tblPlayers(Name) values ('Sourav')
will create the record in the table of the subscriber database as
ID Name
1 Sourav
Both of these insertions are made before the synchronization. So both the databases contain there own data. Through synchronization i want to keep both records in both database. Means i expecting both databases contain two records in the "tblPlayers" table But after synchronization what i get is only the data which is cretaed in the publisher. The data which i added to the subciber will be lost.
Please help me. i don't know how to fix this issue. My clients requirement is in this way. they don't want to loos any data from the subscriber.
July 8, 2009 at 12:57 am
ps (7/8/2009)
If you are entering same records in both publisher and subscriber, the record originating from the publisher takes precedence over the one originating from the subscriber by the conflict resolver and hence only one is allowed to be synchronized to all nodes.
hi,
i would like know about conflict reslover. i have set up a merge replication. but not configured conflict reslover.
is there any default conflict resolver as one u mentioned above.
Regards
ramu
July 8, 2009 at 12:57 am
You need to manage your identity columns
For publisher you should provide a different range and for subscriber you should provide a different range so that conflicts do not occur
This URL should help you in managing your identity columns.
This URL provides good explanation of identity range management on publisher and subscribers.
EDIT - THe URLs posted are for higher versions. Refer http://www.replicationanswers.com/ManualIdentities.asp on how to manage your identity columns.
July 8, 2009 at 1:06 am
ramuvanparti (7/8/2009)
ps (7/8/2009)
If you are entering same records in both publisher and subscriber, the record originating from the publisher takes precedence over the one originating from the subscriber by the conflict resolver and hence only one is allowed to be synchronized to all nodes.hi,
i would like know about conflict reslover. i have set up a merge replication. but not configured conflict reslover.
is there any default conflict resolver as one u mentioned above.
Regards
ramu
Quoting from BOL
The Merge Agent detects conflicts by using the lineage column of the MSmerge_contents system table; if column-level tracking is enabled for an article, the COLV1 column is also used. These columns contain metadata about when a row or column is inserted or updated, and about which nodes in a merge replication topology made changes to the row or column.
....
....
As the Merge Agent enumerates changes to be applied during synchronization, it compares the metadata for each row at the Publisher and Subscriber. The Merge Agent uses this metadata to determine if a row or column has changed at more than one node in the topology, which indicates a potential conflict. After a conflict is detected, the Merge Agent launches the conflict resolver specified for the article with a conflict and uses the resolver to determine the conflict winner. The winning row is applied at the Publisher and Subscriber, and the data from the losing row is written to a conflict table.
I suggest you go through BOL for further understanding of how conflict detection and resolution happens.
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply