Wednesday, March 7, 2012

Error 3726

Hi all,
I am encountering a similar problem to Tom's. I am trying to do a merge repl
with sql 2005 on both ends. I have a decent size db of 1.2 gb. I had the
replication working ok before. But due to some updates I had to apply to a
program , I had to break replication. When get the snapshot made and the try
to sync I get: "The schema script "xxx.sch" could not be propagated to the
subscriber." Upon further digging in the logs I see that I too am getting the
3726 saying "Could not drop object 'dbo.xxx' because it is referenced by a
FOREIGN KEY constraint."
I remember getting this error before and I had re-created the publication a
few times and was somehow able to get it to work. I am not able to get it to
work now. Any insight would be greatly appreciated.
Thanks
"Tom" wrote:

> I am doing a snapshot replication between SQL server 200 and SQLexpress.
> When I sync I get the following error:
> Could not drop object 'Events' because it is referenced by a FOREIGN KEY
> constraint..
> I went into the "Events" table and removed all the foreign keys, but the
> error persists. Also, the database is being used for simple queries and no
> data input.
> Any insight would be appreciated.
> Tom
>
>
>
I answered this in your other post, but I believe Tom's case was different -
certainly the description is distinct in that he mentions he removed the FK
constraints. It might be that he removed them on the publisher! In this case
he does has the same issue and will need to drop them on the subscriber
before the table is dropped eg via a pre-snapshot script.
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com .

No comments:

Post a Comment