You are on page 1of 2

lOMoARcPSD|18509551

Normalization DBMS INT 306

DBMS (Lovely Professional University)

StuDocu is not sponsored or endorsed by any college or university


Downloaded by cutei manisha (5256manisha@gmail.com)
lOMoARcPSD|18509551

Normalization

• It is a technique for designing relational database


tables to minimize duplication of information and
thus, increasing the logical consistency.

• Normalization is used to eliminate various:


○ Anomalies
○ Inconsistencies

• Three types of anomalies from which database may


suffer:
○ Update
○ Insert and
○ Delete

EMP_PROJ (Empno, Projno, Ename, Pname, No_hours)

Ø Update Anomaly:

Due to data redundancy in the database and to make any


modification, one has to change all the copies of the
redundant data.

Ø Insert Anomaly:

Means that some data can not be inserted in the database.

Ø Delete Anomaly:
Means that deleting some data causes other information to be
lost.

Data Consistency:

Same data is having different values at different locations.

To remove these anomalies, this relation needs to be normalized.

• Normalization is decomposed among multiple tables.


• Single table should contain single idea.

Dependencies

• Functional dependency
• Full Functional dependency
• Partial dependency
• Transitive dependency
• Multi-valued dependency

• Functional dependency

Attribute B has a Functional dependency on attribute A, if for


each value of attribute A, there is exactly one value of
attribute B.
Denoted By:
A --> B

A is called determinant and B is called as determined.

Parts
Part_Name Cost A --> B "B is determined by A"
Hard Disk 2000
R
Floppy Disk 20 A B
A B A B C D E A) A--> BC
Mouse 150 a 1
a 1 a 2 3 4 5 B) DE --> C
Hard Disk 2000 b 2 C) C --> DE
a 2 2 a 3 4 5
Keyboard 400 c 3 D) BC --> A
c 3 a 2 3 6 5
Floppy Disk 20 d 4
d 4 a 2 3 6 6
(VALID)
(INVALID)
• Full Functional dependency

An attribute is Full Functional dependent on a set of attributes


S, if it is:

○ Functional dependent on S and


○ Not Functional dependent on any proper subset of S.

Student
RollNo Name Course_id Course_Title Grade
1 Raj CSE301 Database Concepts A
1 Raj CSE306 Computer Networks C
2 Pardeep CSE301 Database Concepts B
2 Pardeep CSE306 Computer Networks A
3 Arun CSE316 Software Engineering C

• Partial dependency

It is relationship between attributes such that the value of one


attribute is dependent on or determined by the value of another
attribute which is part of composite key.

Example
Name attribute partial dependent on the RollNo, because RollNo
is a part of composite key (RollNo, Course_id)

• Transitive dependency

A -->B -->C

Attribute C is functionally dependent on B which is further


dependent on attribute A.

Department

Dept_id Dept_Name Hod_Name


1 CSE A
2 IT B
3 ECE C
4 ME D

Dept_id --> Dept_Name --> Hod_Name

• Multi-Valued dependency

Attribute B has a multi-valued dependency on attribute A, if for


each value of attribute A, there are more than one values of
attribute B.

A --> --> B

Person

Name Mobile_No
Sunil 1
Sunny 2
Name --> --> Mobile_No
Arun 3
Harish 4
Sunil 5
Harish 6 Downloaded by cutei manisha (5256manisha@gmail.com)

You might also like