Development

The Relational database model

The Relational database model or schema is one that uses many tables that are all related to each other, hence the relational name tag.

With the data all being related there is no one main table, instead just many that are references for values throughout the tables.

The benefits of the relational model

Using the relational model means you get a scalable database that is very data-independent for its application. The database has high data integrity and is flexible to being expanded.

The relational model is compact and efficient as strings are rarely or never repeated, instead they get referenced with an id.

Example relational database

Mock example of a sports league Relational database model:

Relational database model example diagram

You can see above that each string has its own table with its own id in that table. This means efficiency is gained on not repeating strings rather much smaller integers.

With a relational modelled database, most tables need to be joined to become human-readable yet can function individually in the internal system.

An example of this is the fixture table, essentially it is all integers with a date string. It needs to be joined with the teams, players and arenas tables to get a name for their respective ids.

A negative for the Relational database model is its susceptibility to become complex and complicated if needing to join many tables.

Reading or storing time-series data could be an issue with the relational model as could be large text values.

 

Share
Tags: MYSQLWeb Dev

Recent Posts

Kennington reservoir drained drone images

A drained and empty Kennington reservoir images from a drone in early July 2024. The…

1 year ago

Merrimu Reservoir drone images

Merrimu Reservoir from drone. Click images to view larger.

1 year ago

FTP getting array of file details such as size using PHP

Using FTP and PHP to get an array of file details such as size and…

2 years ago

Creating Laravel form requests

Creating and using Laravel form requests to create cleaner code, separation and reusability for your…

2 years ago

Improving the default Laravel login and register views

Improving the default Laravel login and register views in such a simple manner but making…

2 years ago

Laravel validation for checking if value exists in the database

Laravel validation for checking if a field value exists in the database. The validation rule…

2 years ago