| Author |
Message |
dblanchett
Joined: 07 Sep 2012 Posts: 1
|
Posted: Fri Sep 07, 2012 9:48 am Post subject: Adding WITH CHECK to Foreign Keys |
|
|
Is there a way to have SQL Compare include the WITH CHECK option when it creates or alters a foreign key constraint? There is an option to do this in SQL Data Compare but I can not see how to do this in the Schema compare.
Thanks |
|
| Back to top |
|
 |
Brian Donahue
Joined: 23 Aug 2004 Posts: 6344 Location: Red Gate Software
|
Posted: Mon Sep 10, 2012 3:26 pm Post subject: |
|
|
Hello,
SQL Compare should script objects exactly as they were created. So if you did not specify, it should recreate foreign keys WITH CHECK. If the foreign key was originally created WITH NOCHECK, it should be recreated that way if it needed to be dropped and created or just newly-created. The way to override that would be to use the Ignore->WITH NOCHECK option. _________________ Brian Donahue
Technical Support
Red Gate Software Ltd.
44 (0)870 160 0037 ext 8521
US and CAN 1-866-RED GATE ext 8521 |
|
| Back to top |
|
 |
|
|
All times are GMT + 1 Hour
|
| Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group