If you create a foreign key using ALTER TABLE ... WITH CHECK ADD CONSTRAINT in one database and in another database you create the same key using ALTER TABLE ... WITH NOCHECK ADD CONSTRAINT followed by an ALTER TABLE ... CHECK CONSTRAINT statement to enable the key, why does SQL Compare see them as different?

I understand that the creation metadata for the keys are different. But I don't care about that. I only care (a) does the key exist in both databases, (b) does it have the same definition and (c) do the enabled flags match?

Is there a filter or other setting in SQL Compare to give me what I want?

Thanks,
wkhazzard
0

Comments

1 comment

  • wkhazzard
    Nevermind. I found it in the options for the compare project. I checked the "WITH NOCHECK" option in the Ignore section and it worked perfectly. Sorry to bother. Thanks!
    wkhazzard
    0

Add comment

Please sign in to leave a comment.