eurocec ebusiness innovations web services





  European Centre of e-Commerce & Publishing


29/12/20

SQL | MySQL Programming | Using MySQL with PHP | Authentication Login System | Content Management System | MySQL 5 Installation |


SQL / Creating the Database Schema


Normalization of a Relational Database Schema



The normalization process, was introduced by Codd in 1970, and its basic function is to apply upon a database schema a set of tests in order to find if the database belongs to a normal form or not.


The normalization process

Codd presented three normal forms (1NF, 2NF and 3NF) which are connected with functional dependencies among the fields of the database tables.


Later two other normal forms are added to normalization methodology (4NF and 5NF) which are based on the multi-valued dependencies and join dependencies.
In this book we discuss the three normal forms of
Codd and focus on them in detail.
Under the normalization procedure a relational database schema is transformed in each stage in a new form analyzing the tables structure based on their primary keys and the functional dependencies that exist among their fields.
These structures must satisfy some conditions.
If they do not, the tables of database are divided into new tables (fewer than before) so that the conditions are met for each one of them. A normal form characterizes a relation (table) in connection with the types of dependencies that there are among its fields.

These dependencies in most of the cases cause problems to the database behavior - such us repeating groups of fields, positional dependency of data and non-atomic data - they must be removed from the tables.
Thus, normalization step by step undertakes to remove from tables structure all these conflict dependencies. 
The following figure shows the step by step process of a database tables normalization.




In the sections that follow we will attempt to simplify the process of normalization as much as possible.
 In your journey in SQL and MySQL database management it is very important to understand the basic concepts.
However, normalization is absolutely one of the most important parts of database design and you must know it if you want to create professional relational database schemas.


The Zero Normal Form - 0NF of a Relational Database

A database that contains data that is common to one or more different tables needs normalization. In such a case there are many reasons why normalization is needed.
Some of them are security, disk space usage, speed of queries, efficiency of database updates, and most importantly data integrity.
As we mentioned earlier normalization is the process of breaking tables into smaller tables whose form is structured by a better logical design.
To follow the normalization process, we pass our database design through the different forms in order.
Through a top-down processing a database schema starts from the normal form - 0NF to become the first normal form - 1NF schema and after that to become the second normal form - 2NF and finally to become the third normal form - 3NF schema.
In each step of normalization, we add more specific conditions that must be satisfied by the schema of the normal form.
A zero normal form - 0NF database before normalization has not been broken down logically into smaller tables.
A spreadsheet layout for a database table is an example of a zero normal form - 0NF.
In this spreadsheet table structure there are:

  • Repeating groups of fields
  • Positional dependency of data
  • Non-Atomic data
The following table is in spreadsheet design:

 







Copyright © euRoCec.eu

The content and services of eurocec.eu are offered under the terms of use which the visitors have accepted.


Sectors: Publishing, e-Business Development, Financial and Investment Consulting, Web Services, WebSite Management, WebSite Optimization, Search Engines Optimization, Web Business Plans, Email Marketing.