在发布服务器上删除损坏的订阅

在发布服务器上删除损坏的订阅

本文介绍了SQL Server复制:在发布服务器上删除损坏的订阅的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们的订户有多个订阅(合并拉),仅1个真实"订阅.我认为我们实际上是通过在订户端添加和删除订阅,然后尝试将其复制...来多次打破这种局面的.

We have multiple subscriptions (merge pull) at our subscriber for only 1 "real" subscription. I think we actually broke it like this by adding and removing the subscription from the subscriber side, and then trying to replicate it... multiple times.

现在的问题不是复制不起作用,我对此很有信心.问题是我无法再在订户上删除/删除损坏的订阅.只是不起作用.

Now the problem is not that the replication does not work, I'm pretty confident that I the answer for that. The problem is that I can't drop/delete the broken subscriptions at the subscriber anymore. It just does not work.

当尝试在发布服务器上运行sp_dropmergepullsubscription时,它告诉我此发布文章没有订阅".

When trying to run sp_dropmergepullsubscription at the publisher, it tells me "No subscription is on this publication article".

当尝试在发布服务器上运行sp_dropsubscription时,它告诉我此数据库未启用订阅"

When trying to run sp_dropsubscription at the publisher, it tells me "This database is not enabled for subscription"

是的,我已经检查过我是否在正确的数据库以及所有这些数据库上运行所有这些脚本.

Yes I've checked that I was running all these scripts on the correct database and all that.

以前有人遇到过这样的问题吗?我需要重新进行发布和订阅吗?

Has anybody had a problem like this before ?Do I need to re-do the publication and the subscription ?

谢谢伙计们! :)

推荐答案

在发布商上尝试以下操作:

Try the following on the publisher:

EXEC sp_dropmergesubscription
  @publication = '<publicationName>',
  @subscriber = '<subscriberName>',
  @subscriber_db = '<dbName>;
GO

delete sysmergesubscriptions where subscriber_server = '<subscriberName>'

use distribution
go
delete msmerge_Agents where subscriber_name = '<subscriberName>'

delete msmerge_subscriptions where subscriber = '<subscriberName>'

...然后尝试备份请求订阅

...then try setting the pull subscription back up

这篇关于SQL Server复制:在发布服务器上删除损坏的订阅的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-06 04:32