Applying check constraints in sqlserver 2005  
Author Message
BCandy





PostPosted: .NET Framework Data Access and Storage, Applying check constraints in sqlserver 2005 Top


.NET Development18  
 
 
Ronald Ricardo Ramirez Moran





PostPosted: .NET Framework Data Access and Storage, Applying check constraints in sqlserver 2005 Top

This is because the Visual Database Tools validates the existing data with the constraint when you attempt to add it. But no problem, you can to decide do not to validate the existing data by changing the property Check Existing data On Creating or re-enabling to NO, but these data will be inconsistent with new rule. Or by using the NO CHECK clausule on ADD CONSTRAINT statement.

A recomendation is to review the data and change it to accept the changes and the new rule.

Regards,



 
 
BCandy





PostPosted: .NET Framework Data Access and Storage, Applying check constraints in sqlserver 2005 Top

([Permission]='operator' OR [Permission]='Supervisor')

for anyone who may need it.