DBMS ~ Normalization - rohit120582sharma/Documentation GitHub Wiki

Normalization should be carried out for every database to make it easier, and more reliable to work with.

It is a set of rules/guidelines/technique that is used while designing a database. These rules help to remove all the redundancies and anomalies.

It split a large table into smaller tables and define relationships between them to increases the clarity in organizing data, reduces redundancy, and query them efficiently and effectively.

It removes all the duplication issues and incorrect data issues, helping to have a well-designed database.

Normalization is divided into following normal forms where each Normal-Form has some formal criteria which relation should satisfy to being in:

First Normal Form (1NF)

  • Each column/field must have a unique name.
  • Each column/field should contain one value, just one value, and there should be no repeating groups.
  • Values for each attribute is atomic. No multi-value.
  • All entries in any column must be of the same kind/type.
  • No rows should have the repeating group of column values.
  • No two rows are identical.

Second Normal Form (2NF)

  • Second Normal Form is only ever a problem when we're using a composite primary key. That is, a primary key made of two or more columns.
  • Every non-key field should be fully and functionally dependent on the entire primary key.
  • No non-key values based on just part of a composite key.

Third Normal Form (3NF)

  • A transitive dependency in a table is a functional dependency between two or more non-key attributes.
  • No non-key field is dependent on any other non-key field.