Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sql Server Service Broker

Status
Not open for further replies.

hatemgamil

Programmer
Mar 18, 2010
41
Greetings,,

i want to make bi-diretctional replication between 2 databases each is one sql server instance,,after searching for the best way to do bi-directional replication i found that i can use service broker to exchange messages between 2 databases ,,but i have a question about conflict detecting and resolution and i need some help,,my question is how can i detect these type of conflicts that can be occured during exchanging messages ,,for examples,,

1-updating the same rows,,if each message containg the rows that are updated on each database .
2-updating rows on 1 database that are deleted on the other,,so when the message from data base 1 will contain an update statement for the rows that have been updated but when it arrives @ database 2 and executed the result will be 0 rows affected because those rows are deleted on database 2..
and there are other conflict,,i need some help or any ideas to know how can resolve those conflict ,,,
any suggestion will be highly apperciated

thnx all
 
Peer-to-peer and merge replication allow conflict detection. In peer-to-peer replication, conflicts stop the Distribution Agent until the conflict is manually resolved; in merge replication you can choose how you want the agent to resolve the conflict. Read up on it in SQL BOL. Here is a good link too
Good luck.

MCP SQL Server 2000, MCTS SQL Server 2005, MCTS SQL Server 2008 (DBD, DBA)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top