【发布时间】:2012-03-13 14:43:33
【问题描述】:
我在 SQL Server 2005 中设置了事务复制,并且禁用了设置复制时创建的 DDL 触发器。在玩了一会儿(了解会发生什么)之后,事务被破坏了,因为我已经将发布者上的一列更改为VARCHAR,即订阅者上的INT。我找到了两个程序,这将有助于跳过这个有问题的事务
EXEC sp_helpsubscriptionerrors
@publisher='DB1',@publisher_db='repl_test',@publication='repl_test_table',
@subscriber='DB2',@subscriber_db='repl_test'
这给了我一个可以看到错误的结果集(将VARCHAR 转换为INT 失败)
id time [...] error_code error_text xact_seqno
24 2012-02-23 08:33:35.313 [...] 8114 Fehler beim Konvertieren des varchar-Datentyps in int. 0x00139791000CC79C000600000000
24 2012-02-23 08:33:35.310 [...] 8114 Fehler beim Konvertieren des varchar-Datentyps in int. 0x00139791000CC79C000600000000
[...]
我使用来自结果 (0x00139791000CC79C000600000000) 的xact_seqno 在下一步执行以下过程
EXEC sp_setsubscriptionxactseqno
@publisher='DB1',@publisher_db='repl_test',@publication='repl_test_table',
@xact_seqno=0x00139791000CC79C000600000000
会说:
错误 20017 - 订阅者不存在订阅。
嗯?
【问题讨论】:
标签: sql-server sql-server-2005 replication transactional-replication