What are the three types of anomalies in database and
Explain?
Answer Posted / a.h nayeem
INSERT Anomaly
1)An insertion anomaly occurs when data cannot be inserted into a database due to other missing data
2)This is most common for fields where a foreign key must not be NULL, but lacks the appropriate data
3)An example of this anomaly can be explained with a simple user database
..A user must have a group ID as a foreign key
..No groups have yet been created
..Thus, a user can not be inserted in to the database as the group ID must not be NULL
4)This can result in data redundancy due to the omission of data.
DELETE Anomaly
1)A deletion anomaly occurs when data is unintentionally lost due to the deletion of other data
2)For example, if a database row contained "Username" and "User Group"
.."John" and "Fred" are in the user group "Contributors"
..If John and Fred are removed from the database, our Contributors group will also disappear
..This is because we haven't normalised our data, meaning the only reference to the Contributors user group lies within the same database row (or record)
..Hence, removing the only two references of our user group results in the loss of data accuracy and integrity
3)This also goes to show why it's important for us to normalise our data and how combining unlike information can be problematic
UPDATE Anomaly
1)An update anomaly occurs when data is only partially updated in a database.
2)A database that hasn't undergone normalisation may reference the same data element in more than one location.
3)As these locations haven't been consolidated and referenced, we have to make sure each location is manually updated
4)This can cause problems as we then need to spend time searching for and updating each reference to the data element.
5)An example of this is a database containing two records; Users and Mailing List.
..John has an email address of john@mail.com in the Users record.
..John has the same email address in the Mailing List record.
..John decides to change his email preferences, which in turn updates the User record for John.
..However, the system did not automatically update the Mailing List record, leaving John with two different associated emails and thus creating inconsistencies within our database.
Is This Answer Correct ? | 25 Yes | 1 No |
Post New Answer View All Answers
Re: Where can i get informatica certification Exam dumps and details? please forward it to emailid:
What is the role of tester in discovery(in Checklist)?
What is the Difference Primary key and Unique Key
how do you do sql tuning?
Explain artificial key?
What is ole db in ssis?
What is odm in database?
what is ad-hoc access? what is the diff b/w managed query and ad-hoc access?
What are different types of blocks used in stored procedure?
What is the best database?
What is ole db used for?
What do you mean by cluster and non cluster index?
Can a database table exist without a primary key?
What do you mean by database?
After normalization, what are the conditions which have to keep in mind to de-normalize it?