[英]SQL server: what does this sql statement mean
I've been comparing databases using vs 2010 scheme comparing tool and it generated some stuff which is not clear. 我一直在使用vs 2010方案比较工具比较数据库,它生成了一些不清楚的东西。 For example at the end of the script it has this statement:
例如,在脚本末尾具有以下语句:
ALTER TABLE [dbo].[My_table] WITH CHECK CHECK CONSTRAINT [FK_FOREIGN_ID];
Can anyone explain what this means? 谁能解释这意味着什么?
That tells SQL Server to validate the constraint against new rows. 这告诉SQL Server验证对新行的约束。 The counter example would be to use
WITH NOCHECK
to temporarily disable validation checks for new rows. 相反的示例是使用
WITH NOCHECK
暂时禁用对新行的验证检查。
ALTER TABLE (Transact-SQL) (WITH CHECK | WITH NOCHECK ) ALTER TABLE(Transact-SQL)(选中| WITH NOCHECK)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.