Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Records in the Conflict tables even though Custom Resolver is working

Posted on 2006-10-24
5
Medium Priority
?
738 Views
Last Modified: 2009-07-29
Hello,

I have merge replication setup between two SQL2000 (SP3a) DBs.

The Subscriber synchronises with the Publisher every 15mins and has been like this for 2 years.

Updates are allowed on both DBs

I am using the Microsoft SQL Server DATETIME (Later Wins) Conflict Resolver to resolve any conflicts where the same record is updated on both DBs.

The "resolve conflicts interactively" option is not enabled.

The resolver is working fine and the record with the latest date always wins.

However I have recently noticed that in EM I can View Conflicts and choose to "Keep winning change" or "Resolve With This Data" on conflicts that have already been resolved.

My question is, although the resolver is working correctly why are records appearing in the Conflict tables?

Should I be concerned by the records in the conflict table or will they be automatically removed after a certain time?



Thanks in advance,


Paul
0
Comment
Question by:paulmward
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 6

Expert Comment

by:Gokulm
ID: 17794554
Conflict viewer displays the results of conflicts that are already resolved. So you need not worry about the records in the conflict table.. below is the extract from BOL...

Interactive Resolver
Microsoft SQL Server replication provides an interactive resolver, which allows you to resolve conflicts manually during on-demand synchronization. Activated at run-time, the Interactive Resolver displays data for each conflicting row, and provides options for viewing and editing the conflict data, and resolving each conflict individually.

Interactive Resolver and the Conflict Viewer
The Interactive Resolver resembles the Conflict Viewer. However, the Conflict Viewer displays the results of conflicts that are already resolved after merge synchronization, and the Interactive Resolver displays each conflict prior to resolution, allowing you to determine the outcome of each conflict during merge synchronization. Someone must be available to monitor the Interactive Resolver when a conflict occurs.
0
 

Author Comment

by:paulmward
ID: 17794635
Thanks Gokulm.

Are the records in the conflict tables maintained/deleted at anytime or will they continue to build up until they are manually deleted?
0
 
LVL 6

Accepted Solution

by:
Gokulm earned 200 total points
ID: 17794791
I guess these need to be manually deleted. You can use the below system stored proc to do so...

sp_deletemergeconflictrow
Deletes rows from a conflict table or the MSmerge_delete_conflicts table. This stored procedure is executed at the computer where the conflict table is stored, in any database.

Syntax
sp_deletemergeconflictrow [ [ @conflict_table = ] 'conflict_table' ]
    [ , [ @source_object = ] 'source_object' ]
    { , [ @rowguid = ] 'rowguid'
    , [ @origin_datasource = ] 'origin_datasource' ] }
    [ , [ @drop_table_if_empty = ] 'drop_table_if_empty' ]

0
 

Author Comment

by:paulmward
ID: 17794917
Thanks for pointing out the sp

I've had a look into it and it looks like it's what I'm after.

What I'm still unsure about is what's the point logging the records in the conflict tables when they've already been resolved.

If it's a case of "that's the way it works" then fine, but I'm just wondering whether there's anything I can do to stop the records from being entered into the conflict tables and therefore having to be maintained?
0
 
LVL 6

Expert Comment

by:Gokulm
ID: 17794946
Conflicts are automatically resolved using the conflict resolver initially selected when the article was created. As conflicts are resolved during synchronization, the data from the losing row is written to a conflict table. The Replication Conflict Viewer allows you to review these conflict records and, potentially, modify your data.

The conflict resolver choices for queued updating subscriptions are:
Publisher wins and the subscription is reinitialized
Publisher wins
Subscriber wins

Note:  The Replication Conflict Viewer displays conflicts that may occur as part merge replication or as part of snapshot or transactional replication whenever updatable subscriptions (immediate updating or queued updating) are used. In the case of snapshot and transactional publication using updatable subscriptions, you will be able to use Replication Conflict Viewer to observe the conflict, but you will not be able to alter the resolution the way you can with conflicts that occur during merge replication synchronization.
0

Featured Post

 [eBook] Windows Nano Server

Download this FREE eBook and learn all you need to get started with Windows Nano Server, including deployment options, remote management
and troubleshooting tips and tricks

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
This month, Experts Exchange sat down with resident SQL expert, Jim Horn, for an in-depth look into the makings of a successful career in SQL.
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question