The relational model: Math at the heart of tables
In 1970, Edgar Codd proposed a revolutionary approach: store data not as tangled lists but as “relations.” In development we call them tables. The main strength of this model is predictability and strict structure that protects data from chaos.
Files vs database
Core terms
How do relationships work?
Relationships in the relational model are supported through keys. A primary key (PK) is the unique “passport” of a row in its table. A foreign key (FK) references a PK in another table: the child points to the parent.
Implementation in SQL
Remember the properties of a “proper” relational table: there should be no fully duplicate rows, row order does not change the meaning of the data, and each column has a unique name within the table.