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
What is redis good for?
If the master device is full, how do I make the master database bigger?
What is ole db provider for sql server?
Is it good to store images in database?
How many types of locks are present in a database?
How to produce such kind of file?
5. Explain about relational algebra.
can u combine pipeline parallelism and partition parallalism? how and whan?
What is Object Oriented model?
HOW PASS PARAMETERS FOLLOWING ORDER RPG-CL-RPG?
how do you do sql tuning?
There are three servers are run by Oracle, MS Access and .Net. What are the procedure fetching the values of two variables from two servers among these?
What is the database url?
What is the best database software for small businesses?
What is the difference between database and server?