Data Integrity and its categories


Enforcing data integrity ensures the quality of the data in the database.For example
    if we entered the emp_id is 1 in a table,the database should not allow other emp_id with the same value of 1.
    if we have an emp_rating column which is intended to have values ranging from 1 to 10,the database should not allow the value except from 1 to 10.
    if we have dept_id column which stores department number for the employee,the database should allow valid department number.
Data Integrity falls into 4 categories.
1)Entity Integrity
2)Domain Integrity
3)Referential Integrity
4) User-defined integrity

No comments:

Post a Comment