Subscriber status using ReplicationMonitor.
-
Monday, March 05, 2012 10:32 PM
I'm using a push merge subscription and I need to programmatically determine if replication is occuring between the publisher and the subscribers.
If a merge failure occurs or the publication stops synchronizing I need to be able to pick up the change in status and notify the user on the client side.
Using RMO I can query the publication manager and get all subscribers. For each subscriber I can get a status as well as action/start date times but the status only goes between Started and Succeeded.
Besides action/start date times is there something I can use to determine replication status (errors). How can I simulate a failure (stopping synchronization doesn't cause an error or change in status).
Thanks.
All Replies
-
Tuesday, March 06, 2012 2:51 PM
Hi
For monitoring check procedure sp_replmonitorhelppublication or How to: Programmatically Monitor Replication (Replication Transact-SQL Programming). You can not simulate error, but you can cause error under controlled environment, for example deny user access or block connection.
everything is a matter of probability...
- Edited by pen_2 Tuesday, March 06, 2012 2:53 PM
- Marked As Answer by Lie YouModerator Monday, March 12, 2012 2:20 AM

