0% found this document useful (0 votes)
31 views12 pages

DB Fundamentals Lecture #

This document discusses database anomalies and normalization. It defines database anomalies as problems in relations that occur due to redundancy, such as insertion, deletion, and modification anomalies. The document then explains different normal forms used in normalization, including 1NF, 2NF, 3NF and BCNF, which are used to produce a simple and reliable database structure. The purposes of normalization are also outlined, such as making the database design efficient, reducing data amounts, and eliminating anomalies.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
31 views12 pages

DB Fundamentals Lecture #

This document discusses database anomalies and normalization. It defines database anomalies as problems in relations that occur due to redundancy, such as insertion, deletion, and modification anomalies. The document then explains different normal forms used in normalization, including 1NF, 2NF, 3NF and BCNF, which are used to produce a simple and reliable database structure. The purposes of normalization are also outlined, such as making the database design efficient, reducing data amounts, and eliminating anomalies.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 12

09/11/2020 Badakhshan University Faculty of Computer 1

Science
Islamic Republic of Afghanistan
Ministry of Higher Education
Badakhshan University
Computer Science Faculty

Database Fundamentals

09/11/2020 Badakhshan University Faculty of Computer 2


Science
Lecture #12

Database Anomalies & Normalization

09/11/2020 Badakhshan University Faculty of Computer 3


Science
Database Anomalies
Database Anomalies are the problems in relations that occur due to
redundancy in the relations.
These anomalies affect the process of inserting , deleting and
modifying data in the relations.
Some important data may be lost if a relation is updated that contains
database anomalies.
It is important to remove these anomalies in order to perform different
processing on the relations without any problem.

09/11/2020 Badakhshan University Faculty of Computer 4


Science
Types of Anomalies
1: Insertion Anomaly:
The insertion anomalies occurs when a new record is inserted in the
relation
In this anomaly the user cannot insert a fact about an entity until he has
an additional fact about another entity.
2: Deletion Anomaly:
The deletion anomaly occurs when the record is deleted from the
relation.
In this anomaly, the deletion of fact about an entity automatically
deletes the fact of another entity.

09/11/2020 Badakhshan University Faculty of Computer 5


Science
Continue…
3: Modification Anomaly:
The modification anomaly occurs when the record is updated in the
relation.
In this anomaly ,the modification in the value of specific attribute
requires modification in all records in which that value occurs.

09/11/2020 Badakhshan University Faculty of Computer 6


Science
Normalization
The process of producing a simple relation and more reliable database
structure is called normalization.
It is used to create a suitable set of relations for storing data.
This process works through different stages known as normal forms.
These stages are 1NF , 2NF , 3NF , BCNF , 4NF , 5NF
Each normal form has certain requirements for condition.
These conditions have to fulfilled to bring the database in that particular
normal form.
In a relation satisfies the conditions of a normal form , it is said to be in
that normal form.

09/11/2020 Badakhshan University Faculty of Computer 7


Science
Purposes of Normalization
It makes the database design efficient in performance.
It reduces the amount of data if possible.
It makes the database design free of update , insertion and deletion
anomalies.
It makes the design according to the rules of relational databases.
It identifies relationship between entities.
It makes a design that allows simple retrieval of data.
It simplifies data maintenance and reduces the need to restructure data.

09/11/2020 Badakhshan University Faculty of Computer 8


Science
Characteristics of Normalized Database

Each relation must have a key field.


All fields must contain atomic data.
There must be no repeating fields.
Each table must contain information about a single entity.
Each field in a relation must depend on key fields.
All non-key fields must be mutually independent.

09/11/2020 Badakhshan University Faculty of Computer 9


Science
Characteristics of Normalized Database

Each relation must have a key field.


All fields must contain atomic data.
There must be no repeating fields.
Each table must contain information about a single entity.
Each field in a relation must depend on key fields.
All non-key fields must be mutually independent.

09/11/2020 Badakhshan University Faculty of Computer 10


Science
Functional Dependency
Functional Dependency is a relationship between attributes.
It mean if one attribute is known, it is possible to obtain the value of
another attribute.
Suppose the entity of STUDENT with (Restration_No,
Student_Name , Class , Email) if value of Registration_No is known
,it is possible to obtain the value of Student_Name, it means that
Student_Name is functionally dependent on Restration_No.
An attribute B is functionally dependent on attribute A, if the value of
A determines the value of B.
Registration_No  Student_Name

09/11/2020 Badakhshan University Faculty of Computer 11


Science
Any Questions
&
Suggestions

Email: [email protected]
Phone: +0789152242

09/11/2020 Badakhshan University Faculty of Computer 12


Science

You might also like