When you attempt to enter data into a table that has a fully enabled CHECK
constraint, you will only be successful if the data doesn’t violate that constraint. If you attempt to enter invalid data, the operation will fail with an error.
But what if you find yourself in the situation where you really must insert data that will violate the CHECK
constraint? Perhaps the constraint no longer applies, or maybe you have an exception where one row is allowed to bypass the constraint. Either way, you won’t be able to enter anything outside the rules of the constraint.
If you find yourself in this situation, you can always disable the constraint. Here’s how to do that using Transact-SQL.