0% found this document useful (0 votes)
3 views

Normalization and Concept of Normal Forms

Normalization is a database design technique aimed at reducing data redundancy and improving data integrity by decomposing tables into smaller, related ones. It is carried out in stages defined by normal forms, including 1NF, 2NF, 3NF, BCNF, 4NF, and 5NF, each with specific rules to ensure efficient database structure. The document provides examples and explanations of each normal form to illustrate the normalization process.

Uploaded by

chomukumar47
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views

Normalization and Concept of Normal Forms

Normalization is a database design technique aimed at reducing data redundancy and improving data integrity by decomposing tables into smaller, related ones. It is carried out in stages defined by normal forms, including 1NF, 2NF, 3NF, BCNF, 4NF, and 5NF, each with specific rules to ensure efficient database structure. The document provides examples and explanations of each normal form to illustrate the normalization process.

Uploaded by

chomukumar47
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 16

NORMALIZATION AND

CONCEPT OF NORMAL FORMS

CHANDRAKANT CHARTI
BCA-III
NORMALIZATION

 Normalization is a database design


technique that reduce data redundancy and
improve data integrity.
 This process involves decomposing or
Optimizing tables into smaller, related tables
and defining relationships between them.
 The primary goal of normalization is to
ensure that the database structure is
efficient and the relationships between data
are logical and clear.
CONCEPT OF NORMAL FORMS

Normalization is typically carried out in stages, each defined by a


‘’normal form’’.
Each normal form has specific rules that a database must meet to be
considered In that form.
There is most common types of Normal Forms are:

1NF (First Normal Form)


2NF (Second Normal Form)
3NF (Third Normal Form)
BCNF (Boyce-Codd Normal Form)
4NF (Fourth Normal Form)
5NF (Fifth Normal Form)
1NF (FIRST NORMAL FORM)
o A relation will be in 1NF if it contains an atomic value.
o First Normal Form disallows the multi-valued attributes.
o Identify each set of related data with a primary key.
o Remove repeating groups from the table.
o Create a separate table for each set of relation data.
Example: Employee Table Before Apply 1NF -
EMP_ID EMP_NAME EMP_CONTACT NO. EMP_STATE

17 VIJAY 7754364466 CG
7898667777
20 ROHIT 9975759911 MP

15 DEV 8978977887 UP
Employee Table After Apply 1NF -

EMP_ID EMP_NAME EMP_CONTACT EMP_STATE


NO.

17 VIJAY 7754364466 CG

17 VIJAY 7898667777 CG

20 ROHIT 9975759911 MP

15 DEV 8978977887 UP
2NF (SECOND NORMAL
FORM)
o In the 2NF, relational must be in 1NF.
o In the second normal form all non-key attributes are fully functional
dependent on the primary key.
o In a table of the second normal form disallow or not contain any
partial dependency .
Example: Teacher Table -

TEACHER_ID SUBJECT TEACHER_AGE


1725 CHEMISTRY 30
1725 BIOLOGY 30
1747 ENGLISH 35
In the given table, non-prime attribute
1783 MATHEMATICS 38
TEACHER_AGE is dependent on TEACHER_ID
1783 COMPUTER 38 which is a proper subset of a candidate key.
That’s why its violate the rule for 2NF.
To convert the given table into 2NF, we decompose it into two tables:
TEACHER_DETAIL TABLE-

TEACHER_ID TEACHER_AGE

1725 30

1747 35

1783 38

EACHER_SUBJECT TABLE-
TEACHER_ID SUBJECT

1725 CHEMISTRY

1725 BIOLOGY

1747 ENGLISH

1783 MATHEMATICS

1783 COMPUTER
3NF (THIRD NORMAL
FORM)
o A table will be in 3NF if, it is in 2NF and if there is NO TRANSITIVE
DEPENDENCY for Non-prime attributes.
o 3NF used to reduce the data duplication , it also used to achieve
the data integrity.
Example: Student Table -
STUDENT_NA ROLL_NO. PIN_CODE CITY STATE
ME

RAKESH 1001 495001 BILASPUR CG

SURAJ 1006 495221 KORBA CG

AJAY 1023 495770 CHAMPA CG

In the above student table, the column ‘Roll_No.’ is the primary key.
Pin_Code is a non-prime column but it is related to city and state, so
this table can be normalized using 3NF in the following way:-
STUDENT_NAME ROLL_NO. PIN_CODE

RAKESH 1001 495001

SURAJ 1006 495221

AJAY 1023 495770

The above table can be converted into another table for addresses which can be as follows:
Address Table :
PIN_CODE CITY STATE

495001 BILASPUR CG

495221 KORBA CG

495770 CHAMPA CG
BCNF (BOYCE CODD NORMAL
FORM)
o Boyce-codd normal form (BCNF) is an advanced version of the third
normal form. It also known as 3.5NF.
o A table is in BCNF if , it is 3NF and for any dependency A B, A
should be a super key of relation.
o It is based on the concept of determinate.
o It is Stricter form of 3NF.
Example: Student Table -

ROLL_NO. STUDENT_NAME BRACH_ID BRANCH_NAME

1001 PRAKASH 121 CSE

1002 SHYAM 122 AIML

1003 RAJA 123 DS

1004 ANMOL 121 CSE


AFTER NORMALIZED USING BCNF IN THE FOLLOWING WAY:

STUDENT TABLE : BRANCH TABLE :

ROLL_NO. STUDENT_NAME BRACH_ID BRANCH_NAME

1001 PRAKASH
121 CSE

1002 SHYAM
122 AIML
1003 RAJA

123 DS
1004 ANMOL
4NF (FOURTH NORMAL
FORM)
o A relation will be in 4NF , if it is in BCNF and has no Multi-Valued
Dependency.
o In this table only non-primary column depends on one primary key
column.
o For a dependency A → B, if for a single value of A, multiple values of B
exists,Student
Example: then the relation
Table - will be a multi-valued dependency.
STD_ID COURSE HOBBY
1001 CSE DANCING
1002 AIML CRICKET
1003 DS SINGING
AFTER APPLY 4NF -
STD_ID COURSE STD_ID HOBBY
1001 CSE 1001 DANCING
1002 AIML 1002 CRICKET
1003 DS 1003 SINGING
5NF (FIFTH NORMAL FORM)
o The 5NF is also known as PROJECT JOIN Normal Form.
o A relation is in fifth normal form if it is in 4NF and it does not
consist any join dependency.
o 5NF is satisfied when all the tables present in the DBMS are broken
down into as many more tables to ensure there is No Redundancy.

Example: Faculty Table -

SUBJECT FACULTY YEAR

C LOKESH 1

C AMIT 1

JAVA YASH 2

DBMS RAVI 3
AFTER APPLY 5NF : -

Table 1 Table 2 Table 3

SUBJECT FACULTY FACULTY YEAR SUBJECT YEAR

C LOKESH LOKESH 1
C 1

C AMIT AMIT 1

JAVA 2

JAVA YASH YASH 2

DBMS 3
DBMS RAVI RAVI 3
THANKS TO ALL OF YOU FOR
ATTENTION TO MY
PRESENTATION

You might also like