Q. What is Database Normalization? Why do we need to normalize database? Explain with examples. (3+4)marks
The objectives of database normalization:
- It reduces the chances for anomalies to occur in a database.
- To avoid creating and updating any unwanted data connections and dependencies.
- To prevent unwanted deletions of data.
- To optimize storage space.
- To reduce the delay and complexity of checking databases when new types of data need to be introduced.
- It is helpful to divide the large database table into smaller tables and link them using relationship.
- 1NF: Removes duplicates and creates separate tables for groups of related data.
- 2NF: Removes subgroups of data present in multiple rows of a table and creates new tables, with connections between them.
- 3NF: Deletes columns that do not depend on the main key value.
- 4NF: Deletes all dependencies between multiple values
- Data Consistency
- Sound Data Connection
- Connection to other systems
- Cost Saving
- Increased Security
The purpose of normalization is to store each row of data only once, to avoid data anomalies.
A database table looks like a spreadsheet. One item of data, such as a first name, a last name, a phone number, or a street address, appears in each box, or cell, at each intersection of a row and column.
When you normalize a database, you have four goals: arranging data into logical groupings , minimizing the amount of duplicate data , building a database in which you can access and manipulate the data quickly and efficiently without compromising the integrity of the data.
Data normalization helps you design new databases to meet these goals or to test databases to see whether they meet the goals.
Data normalization is primarily important in the transactional, or online transactional processing (OLTP), database world, in which data modifications (e.g., inserts, updates, deletes) occur rapidly and randomly throughout the stored data.
The need for normalization is basically for making sure that a table contains only data directly related to the primary key, that each data field contains only one item of data, and that redundant (duplicated and unnecessary) data is eliminated.
Data normalization example-
Stay safe. Thank you!
No comments:
Post a Comment