Data Integrity

Set of rules and constraints that ensure data consistency and validity within a relational database, maintaining trust through keys and constraints.

« Back to Glossary Index


We call integrity the set of rules and constraints that ensure the consistency, correctness, and validity of data within a relational database model. Its goal is to guarantee that the data faithfully represent the real world and that no anomalies occur due to incorrect data insertion, modification, or deletion.

Data Integrity image of concept in relational database model.

Integrity rules are essential to maintain system consistency and to prevent logical errors or redundancy. They are generally defined through constraints within the Database Management System (DBMS).

Main types of integrity rules

  • Domain integrity: ensures that each attribute contains valid and coherent values according to its data type and defined conditions (e.g. age > 0).
  • Entity integrity: ensures that each row is unique and identifiable through a primary key (PRIMARY KEY) that cannot be null or duplicated.
  • Referential integrity: maintains consistency between related tables through foreign keys (FOREIGN KEY), which require that referenced values exist in the main table.
  • Business integrity: defines rules specific to the business logic or context (for example, an end date cannot be earlier than a start date).

In summary: data integrity is essential to ensure the reliability of information and trust in the systems that depend on it, especially in corporate and analytical environments where decisions are data-driven.

« Back to Glossary Index