Relational Model in DBMS

E.F. Codd proposed the Relational Model to model data in the form of relations or tables. After creating the database conceptual model using an ER diagram, we must transform it to a relational model. We can implement using any RDBMS language ,for example, Oracle SQL or MySQL.

What is a Relational Model and how does it work?

The Relational Model depicts how data in Relational Databases is stored. A relational database is a database that holds information in the form of relationships. A table containing columns and rows basically help to represent this model. Each row is a tuple. A name or attribute is assigned to each table in the column.

Properties of Relations

The relation’s name is separate from the names of all other relatives.
There is just one atomic (single) value in each relation cell.
Each attribute have a unique name.
The domain of an attribute has no meaning.
There are no duplicate values in tuple.
The sequence of a tuple can be different.

Constraints in Relational Model

We set specific requirements that must hold for data in the database while developing a Relational Model. These conditions are basically the Constraints. Before executing any database operation (insertion, deletion, or update), these constraints need a check. The operation will fail if it violates any of the constraints.
Domain Constraints: These are constraints at the attribute level. Only values that fall within the domain range can be assigned to an attribute.
Key Integrity: Every database connection should have at least one set of characteristics that uniquely defines a tuple. The set of qualities is basically a key. There are two characteristics of a key:
For all tuples, it should be unique.
There can’t be any NULL values in it.
Referential Integrity is when one attribute of a relation can only take values from other attributes of the same relation or any other connection.