SlideShare a Scribd company logo
4
Most read
8
Most read
9
Most read
Normalization By Jason Park Fall 2005 CS157A
Database Normalization Database normalization  is the process of removing redundant data from your tables in to improve storage efficiency, data integrity, and scalability.  In the relational model, methods exist for quantifying how efficient a database is. These classifications are called  normal forms  (or  NF ), and there are algorithms for converting a given database between them. Normalization generally involves splitting existing tables into multiple ones, which must be re-joined or linked each time a query is issued.
History Edgar F. Codd first proposed the process of normalization and what came to be known as the  1st normal form  in his paper  A Relational Model of Data for Large Shared Data Banks  Codd stated: “ There is, in fact, a very simple elimination procedure which we shall call normalization. Through decomposition nonsimple domains are replaced by ‘ domains whose elements are atomic (nondecomposable) values.’”
Normal Form Edgar F. Codd originally established three normal forms: 1NF, 2NF and 3NF. There are now others that are generally accepted, but 3NF is widely considered to be sufficient for most applications. Most tables when reaching 3NF are also in BCNF (Boyce-Codd Normal Form).
Table 1 Title Author1 Author2 ISBN Subject Pages Publisher Database System Concepts Abraham Silberschatz Henry F. Korth 0072958863 MySQL, Computers 1168 McGraw-Hill Operating System Concepts Abraham Silberschatz Henry F. Korth 0471694665 Computers 944 McGraw-Hill
Table 1 problems This table is not very efficient with storage. This design does not protect data integrity.  Third, this table does not scale well.
First Normal Form In our Table 1, we have two violations of First Normal Form:  First, we have more than one author field,  Second, our subject field contains more than one piece of information. With more than one value in a single field, it would be very difficult to search for all books on a given subject.
First Normal Table Table 2 Title Author ISBN Subject Pages Publisher Database System Concepts Abraham Silberschatz 0072958863 MySQL 1168 McGraw-Hill Database System Concepts Henry F. Korth 0072958863 Computers 1168 McGraw-Hill Operating System Concepts Henry F. Korth 0471694665 Computers 944 McGraw-Hill Operating System Concepts Abraham Silberschatz 0471694665 Computers 944 McGraw-Hill
We now have two rows for a single book. Additionally, we would be violating the Second Normal Form… A better solution to our problem would be to separate the data into separate tables- an Author table and a Subject table to store our information, removing that information from the Book table:
Subject Table Author Table Book Table Subject_ID Subject 1 MySQL 2 Computers Author_ID Last Name First Name 1 Silberschatz Abraham 2 Korth Henry ISBN Title Pages Publisher 0072958863 Database System Concepts 1168 McGraw-Hill 0471694665 Operating System Concepts 944 McGraw-Hill
Each table has a primary key, used for joining tables together when querying the data. A primary key value must be unique with in the table (no two books can have the same ISBN number), and a primary key is also an index, which speeds up data retrieval based on the primary key.  Now to define relationships between the tables
Relationships Book_Author Table Book_Subject   Table ISBN Author_ID 0072958863 1 0072958863 2 0471694665 1 0471694665 2 ISBN Subject_ID 0072958863 1 0072958863 2 0471694665 2
Second Normal Form As the First Normal Form deals with redundancy of data across a horizontal row, Second Normal Form (or 2NF) deals with redundancy of data in vertical columns.  As stated earlier, the normal forms are progressive, so to achieve Second Normal Form, the tables must already be in First Normal Form.  The Book Table will be used for the 2NF example
2NF Table Publisher Table Book Table Publisher_ID Publisher Name 1 McGraw-Hill ISBN Title Pages Publisher_ID 0072958863 Database System Concepts 1168 1 0471694665 Operating System Concepts 944 1
2NF Here we have a one-to-many relationship between the book table and the publisher. A book has only one publisher, and a publisher will publish many books. When we have a one-to-many relationship, we place a foreign key in the Book Table, pointing to the primary key of the Publisher Table. The other requirement for Second Normal Form is that you cannot have any data in a table with a composite key that does not relate to all portions of the composite key.
Third Normal Form Third normal form (3NF) requires that there are no functional dependencies of non-key attributes on something other than a candidate key.  A table is in 3NF if all of the non-primary key attributes are mutually independent  There should not be transitive dependencies
Boyce-Codd Normal Form BCNF requires that the table is 3NF and only determinants are the candidate keys
END

More Related Content

PPTX
Normalization in DBMS
PPTX
And or graph
PPTX
DBMS - RAID
PPTX
Entity Relationship Diagrams
PPTX
Presentation on Elementary data structures
PPT
2.Problems Problem Spaces and Search.ppt
PDF
Triggers and active database
PPTX
Distributed operating system
Normalization in DBMS
And or graph
DBMS - RAID
Entity Relationship Diagrams
Presentation on Elementary data structures
2.Problems Problem Spaces and Search.ppt
Triggers and active database
Distributed operating system

What's hot (20)

PPTX
Hadoop And Their Ecosystem ppt
PPTX
DML, DDL, DCL ,DRL/DQL and TCL Statements in SQL with Examples
PPT
Joins in SQL
PPT
Iterative deepening search
PPTX
File Management in Operating System
PPTX
Distributed database management system
PDF
Dbms Notes Lecture 9 : Specialization, Generalization and Aggregation
PDF
The Object Model
PPT
2. Entity Relationship Model in DBMS
PPTX
Three main Architectures For Parallel Database.pptx
PDF
Unit 1: Introduction to DBMS Unit 1 Complete
PPTX
Major issues in data mining
ODP
ER Model in DBMS
PPTX
Data cubes
PPTX
contiguous memory allocation.pptx
PPTX
SQL Joins.pptx
PPTX
Distributed design alternatives
PPT
Problems, Problem spaces and Search
PPTX
Timestamp protocols
PPT
Map reduce in BIG DATA
Hadoop And Their Ecosystem ppt
DML, DDL, DCL ,DRL/DQL and TCL Statements in SQL with Examples
Joins in SQL
Iterative deepening search
File Management in Operating System
Distributed database management system
Dbms Notes Lecture 9 : Specialization, Generalization and Aggregation
The Object Model
2. Entity Relationship Model in DBMS
Three main Architectures For Parallel Database.pptx
Unit 1: Introduction to DBMS Unit 1 Complete
Major issues in data mining
ER Model in DBMS
Data cubes
contiguous memory allocation.pptx
SQL Joins.pptx
Distributed design alternatives
Problems, Problem spaces and Search
Timestamp protocols
Map reduce in BIG DATA
Ad

Viewers also liked (20)

PPT
DBMS - Normalization
PDF
Database design & Normalization (1NF, 2NF, 3NF)
PPT
Databases: Normalisation
PPTX
Database Normalization
PPT
Normalization
PPT
Database Normalization 1NF, 2NF, 3NF, BCNF, 4NF, 5NF
PPTX
PPTX
Normalization
PPTX
Database Concept - Normalization (1NF, 2NF, 3NF)
PPT
Database management system
PDF
TIMEN: An Open Temporal Expression Normalisation Resource
PPTX
Normalisation lesson plan
PDF
Normalisation
PPTX
Database Normalisation
PDF
Normalisation student summary
PPTX
Importance of Normalization
PPT
Normalisation
PPT
Teradata 13.10
PPTX
Dbms and sqlpptx
PPT
functional dependencies with example
DBMS - Normalization
Database design & Normalization (1NF, 2NF, 3NF)
Databases: Normalisation
Database Normalization
Normalization
Database Normalization 1NF, 2NF, 3NF, BCNF, 4NF, 5NF
Normalization
Database Concept - Normalization (1NF, 2NF, 3NF)
Database management system
TIMEN: An Open Temporal Expression Normalisation Resource
Normalisation lesson plan
Normalisation
Database Normalisation
Normalisation student summary
Importance of Normalization
Normalisation
Teradata 13.10
Dbms and sqlpptx
functional dependencies with example
Ad

Similar to Normalization (20)

PPT
Normalization Accepted
PPTX
Normalization presentation in Database Management System
PPTX
Karan normalization in sql
PPT
Normalization
PPT
Jason Park Normalization
PPT
Normalization PRESENTATION
PPTX
Database Normalization.pptx
PPT
Normalization
PDF
Assignment#11
PPTX
Database normalization
PDF
Dependencies in various topics like normalisation and its types
PDF
What is Database NormalizationExplain the guidelines for ensuring t.pdf
PPT
Normalization
PPTX
Normalization and its various types in DBMS
PDF
Advanced Normalization
DOCX
Research gadot
PPTX
Kumar lav
PPTX
Normal forms
PPTX
DBMS: Week 10 - Database Design and Normalization
PDF
Relational Theory for Budding Einsteins -- LonestarPHP 2016
Normalization Accepted
Normalization presentation in Database Management System
Karan normalization in sql
Normalization
Jason Park Normalization
Normalization PRESENTATION
Database Normalization.pptx
Normalization
Assignment#11
Database normalization
Dependencies in various topics like normalisation and its types
What is Database NormalizationExplain the guidelines for ensuring t.pdf
Normalization
Normalization and its various types in DBMS
Advanced Normalization
Research gadot
Kumar lav
Normal forms
DBMS: Week 10 - Database Design and Normalization
Relational Theory for Budding Einsteins -- LonestarPHP 2016

Recently uploaded (20)

PPTX
Pharmacology of Heart Failure /Pharmacotherapy of CHF
PPTX
1st Inaugural Professorial Lecture held on 19th February 2020 (Governance and...
PDF
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
PPTX
PPH.pptx obstetrics and gynecology in nursing
PDF
2.FourierTransform-ShortQuestionswithAnswers.pdf
PPTX
PPT- ENG7_QUARTER1_LESSON1_WEEK1. IMAGERY -DESCRIPTIONS pptx.pptx
PDF
BÀI TẬP BỔ TRỢ 4 KỸ NĂNG TIẾNG ANH 9 GLOBAL SUCCESS - CẢ NĂM - BÁM SÁT FORM Đ...
PDF
Computing-Curriculum for Schools in Ghana
PDF
01-Introduction-to-Information-Management.pdf
PPTX
Lesson notes of climatology university.
PDF
Supply Chain Operations Speaking Notes -ICLT Program
PPTX
Cell Structure & Organelles in detailed.
PDF
O5-L3 Freight Transport Ops (International) V1.pdf
PDF
Anesthesia in Laparoscopic Surgery in India
PDF
Module 4: Burden of Disease Tutorial Slides S2 2025
PPTX
GDM (1) (1).pptx small presentation for students
PDF
Saundersa Comprehensive Review for the NCLEX-RN Examination.pdf
PPTX
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PDF
Basic Mud Logging Guide for educational purpose
PDF
TR - Agricultural Crops Production NC III.pdf
Pharmacology of Heart Failure /Pharmacotherapy of CHF
1st Inaugural Professorial Lecture held on 19th February 2020 (Governance and...
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
PPH.pptx obstetrics and gynecology in nursing
2.FourierTransform-ShortQuestionswithAnswers.pdf
PPT- ENG7_QUARTER1_LESSON1_WEEK1. IMAGERY -DESCRIPTIONS pptx.pptx
BÀI TẬP BỔ TRỢ 4 KỸ NĂNG TIẾNG ANH 9 GLOBAL SUCCESS - CẢ NĂM - BÁM SÁT FORM Đ...
Computing-Curriculum for Schools in Ghana
01-Introduction-to-Information-Management.pdf
Lesson notes of climatology university.
Supply Chain Operations Speaking Notes -ICLT Program
Cell Structure & Organelles in detailed.
O5-L3 Freight Transport Ops (International) V1.pdf
Anesthesia in Laparoscopic Surgery in India
Module 4: Burden of Disease Tutorial Slides S2 2025
GDM (1) (1).pptx small presentation for students
Saundersa Comprehensive Review for the NCLEX-RN Examination.pdf
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
Basic Mud Logging Guide for educational purpose
TR - Agricultural Crops Production NC III.pdf

Normalization

  • 1. Normalization By Jason Park Fall 2005 CS157A
  • 2. Database Normalization Database normalization is the process of removing redundant data from your tables in to improve storage efficiency, data integrity, and scalability. In the relational model, methods exist for quantifying how efficient a database is. These classifications are called normal forms (or NF ), and there are algorithms for converting a given database between them. Normalization generally involves splitting existing tables into multiple ones, which must be re-joined or linked each time a query is issued.
  • 3. History Edgar F. Codd first proposed the process of normalization and what came to be known as the 1st normal form in his paper A Relational Model of Data for Large Shared Data Banks Codd stated: “ There is, in fact, a very simple elimination procedure which we shall call normalization. Through decomposition nonsimple domains are replaced by ‘ domains whose elements are atomic (nondecomposable) values.’”
  • 4. Normal Form Edgar F. Codd originally established three normal forms: 1NF, 2NF and 3NF. There are now others that are generally accepted, but 3NF is widely considered to be sufficient for most applications. Most tables when reaching 3NF are also in BCNF (Boyce-Codd Normal Form).
  • 5. Table 1 Title Author1 Author2 ISBN Subject Pages Publisher Database System Concepts Abraham Silberschatz Henry F. Korth 0072958863 MySQL, Computers 1168 McGraw-Hill Operating System Concepts Abraham Silberschatz Henry F. Korth 0471694665 Computers 944 McGraw-Hill
  • 6. Table 1 problems This table is not very efficient with storage. This design does not protect data integrity. Third, this table does not scale well.
  • 7. First Normal Form In our Table 1, we have two violations of First Normal Form: First, we have more than one author field, Second, our subject field contains more than one piece of information. With more than one value in a single field, it would be very difficult to search for all books on a given subject.
  • 8. First Normal Table Table 2 Title Author ISBN Subject Pages Publisher Database System Concepts Abraham Silberschatz 0072958863 MySQL 1168 McGraw-Hill Database System Concepts Henry F. Korth 0072958863 Computers 1168 McGraw-Hill Operating System Concepts Henry F. Korth 0471694665 Computers 944 McGraw-Hill Operating System Concepts Abraham Silberschatz 0471694665 Computers 944 McGraw-Hill
  • 9. We now have two rows for a single book. Additionally, we would be violating the Second Normal Form… A better solution to our problem would be to separate the data into separate tables- an Author table and a Subject table to store our information, removing that information from the Book table:
  • 10. Subject Table Author Table Book Table Subject_ID Subject 1 MySQL 2 Computers Author_ID Last Name First Name 1 Silberschatz Abraham 2 Korth Henry ISBN Title Pages Publisher 0072958863 Database System Concepts 1168 McGraw-Hill 0471694665 Operating System Concepts 944 McGraw-Hill
  • 11. Each table has a primary key, used for joining tables together when querying the data. A primary key value must be unique with in the table (no two books can have the same ISBN number), and a primary key is also an index, which speeds up data retrieval based on the primary key. Now to define relationships between the tables
  • 12. Relationships Book_Author Table Book_Subject Table ISBN Author_ID 0072958863 1 0072958863 2 0471694665 1 0471694665 2 ISBN Subject_ID 0072958863 1 0072958863 2 0471694665 2
  • 13. Second Normal Form As the First Normal Form deals with redundancy of data across a horizontal row, Second Normal Form (or 2NF) deals with redundancy of data in vertical columns. As stated earlier, the normal forms are progressive, so to achieve Second Normal Form, the tables must already be in First Normal Form. The Book Table will be used for the 2NF example
  • 14. 2NF Table Publisher Table Book Table Publisher_ID Publisher Name 1 McGraw-Hill ISBN Title Pages Publisher_ID 0072958863 Database System Concepts 1168 1 0471694665 Operating System Concepts 944 1
  • 15. 2NF Here we have a one-to-many relationship between the book table and the publisher. A book has only one publisher, and a publisher will publish many books. When we have a one-to-many relationship, we place a foreign key in the Book Table, pointing to the primary key of the Publisher Table. The other requirement for Second Normal Form is that you cannot have any data in a table with a composite key that does not relate to all portions of the composite key.
  • 16. Third Normal Form Third normal form (3NF) requires that there are no functional dependencies of non-key attributes on something other than a candidate key. A table is in 3NF if all of the non-primary key attributes are mutually independent There should not be transitive dependencies
  • 17. Boyce-Codd Normal Form BCNF requires that the table is 3NF and only determinants are the candidate keys
  • 18. END