0% found this document useful (0 votes)
13 views2 pages

U3T2 Update Anamalies

Anomalies in relational databases refer to inconsistencies that arise during data insertion, deletion, and updating, categorized into insertion, deletion, and update anomalies. These issues are often caused by poor database management, lack of normalization, and data redundancy, leading to data integrity problems. Normalization is necessary to prevent these anomalies and ensure consistent data management.

Uploaded by

joyalprincess
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views2 pages

U3T2 Update Anamalies

Anomalies in relational databases refer to inconsistencies that arise during data insertion, deletion, and updating, categorized into insertion, deletion, and update anomalies. These issues are often caused by poor database management, lack of normalization, and data redundancy, leading to data integrity problems. Normalization is necessary to prevent these anomalies and ensure consistent data management.

Uploaded by

joyalprincess
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 2

Anomalies

 Anomalies in the relational model refer to inconsistencies or error that can arise when working with
relational database, Specifically in the context of data insertion , deletion , and updating.

 There are different types of anomalies that can occur in referencing and referenced relations which can
be dicussed as:

 There anomalies can be categorized into three types.

1. Insertion Anomalies

2. Deletion Anomalies

3. Update Anomalies

How are anomalies caused in DBMS?

 Anomalies in DBMS are caused by poor management of storing everything in the flat database, lack of
normalizarion, data redundancy , and improper use of primary of foreign keys.

 Thses issues result in inconsistencies during insert , update ,delete operations , leading to data
integrity problem . These are three types of anomalies that occure when the database is not
normalized.

Insertion Anomalies

These anomalies occur when it is not possible to insert data into a database because the required fields
are missing or because the data is incomplete.

table-1 : STUDENT

stu_no stu_Name mobile state country age

1 RAM 2121212 Haryana ind 20

2 RAM 5252525252 Punjab ind 22

3 Suresh 8787877787 TN ind 23

4 rahul 77778787 kerala ind 44

Table-2: COURSE

stu_no course_No Course_name

1 C1 DBMS

2 C2 JAVA

1 C2 JAVA
 If a tuple is inserted in referencing relation and referencing attribute value is not present in referenced
attribute, it will not allow inserting in referencing relation .

 For Example: if we try to insert a record in COURSE table with Stu_no=7 means it wil not allow because
in rerenced table there in no stu_no is 7 so we can't use this stu_no in referencing table.

Update Anomalies

 These anomalies occur when modifying data in a database and can result in inconsistencies or errors.

empid empname empaddress dept

121 A cbe D1

121 A cbe D2

122 B che D8

123 F erd D9

133 F erd D4

 for Example: if a database contains information

 the above table is not normalized . we will see the problem, that we face when a table is not
normalized.

 in above table we have two rows for employee A as he belongs to two departments of the company.

 if we want to update the address of A then we have to update the same in two rows or the data will
become inconsistent.

 If somehow the correct address gets updated in one department but not in other then as per the
database.

 "A" would be having two different address , which is not correct and would leads to inconsistent data.

Delete Anomalies

 Suppose , if at point of time the company closes the department D8 then deleting the rows that are
having emp_dept as D8 would also delete the information of employee "B" since he is assigned only to
this department.

 to overcome these anomalies we need to normalize the data.

You might also like