Groups | Blog | Home
all groups > sql server replication > september 2006 >

sql server replication : Error 3726


Paul Ibison
9/20/2006 12:00:00 AM
It's not clear from your question, but did you remove the FKs on the
subscriber and not the publisher? Also, just to confirm, on the subscriber
when you run sp_help 'events'
is the final section blank?
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com

Tom
9/20/2006 2:15:23 AM
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



Hilary Cotter
9/20/2006 5:31:16 AM
Right click on your publication, select properties, click on the articles
tab, and select each of your articles individually. In the snapshot tab,
clear then include dri check box. Then regenerate your snapshot and try
again.
--
Hilary Cotter
Director of Text Mining and Database Strategy
RelevantNOISE.Com - Dedicated to mining blogs for business intelligence.

This posting is my own and doesn't necessarily represent RelevantNoise's
positions, strategies or opinions.

Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html

Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com



[quoted text, click to view]

Alex McD
11/8/2006 8:15:01 AM
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

[quoted text, click to view]
Paul Ibison
11/8/2006 4:46:10 PM
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 .

AddThis Social Bookmark Button