Question on constrains
Posted on 2011-02-23
I have two databases I am trying to sync with RedGate's SQL Compare.
Objects such as tables have slight differences and thats OK, but one database has one constrain in that object and another has a different constrain in the same object. Don't ask me why.
Question: What happens if I drop the constrains on both databases so I can run my sync ?
Question: Is there a way to drop ALL constrains in all tables of a database, if so .. how ? if not, how do I drop constrains from one table ?
Question: What could happen if I drop constrins from one table
My constrains look something similar to:
ALTER TABLE [dbo].[Cases] ADD PRIMARY KEY NONCLUSTERED ([Id])
ALTER TABLE [dbo].[LawFirm] ADD PRIMARY KEY CLUSTERED ([FirmId])
I am using MS SQL 2008 Server