SQL Constraints are used to specify rules for the data in a table. It is used to limit the type of data while inserting into the table.
So these are predefined rules and restrictions on single or multiple columns, regarding the value allowed in the columns to maintain the integrity, accuracy and reliability of that columns data.
- Not Null Constraint
- Check Constraint
- Default Constraint
- Unique Constraint
- Primary Key Constraint
- Foreign Key Constraint
Click on each link for the more details with example.
No comments:
Post a Comment