Constraints
Constraints are application rules that SQL Server enforces for you. Constraints limit the possible values that users can enter into a column or columns. They provide following advantages:
-
You can associate multiple constraints with a column, and you can associate a constraint with multiple columns.
-
You create constraints when you create a table with the CREATE TABLE statement. You don't have to bind constraints manually, as you do with defaults.
-
Constraints conform to the ANSI standard for creating and altering tables; they are not Transact-SQL extensions.
-
You can use constraints to enforce referential integrity. Referential integrity is the process of preserving defined relationships between tables when you enter or delete records in those tables.
For details on constraints, see Using Constraints to Enforce Data Integrity.