Open navigation menu
Close suggestions
Search
Search
en
Change Language
Upload
Sign in
Sign in
Download free for days
0 ratings
0% found this document useful (0 votes)
243 views
11 pages
Database Normalization
Uploaded by
comev27121
AI-enhanced title
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here
.
Available Formats
Download as PDF or read online on Scribd
Download
Save
Save DATABASE NORMALIZATION For Later
Share
0%
0% found this document useful, undefined
0%
, undefined
Print
Embed
Report
0 ratings
0% found this document useful (0 votes)
243 views
11 pages
Database Normalization
Uploaded by
comev27121
AI-enhanced title
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here
.
Available Formats
Download as PDF or read online on Scribd
Carousel Previous
Carousel Next
Download
Save
Save DATABASE NORMALIZATION For Later
Share
0%
0% found this document useful, undefined
0%
, undefined
Print
Embed
Report
Download
Save DATABASE NORMALIZATION For Later
You are on page 1
/ 11
Search
Fullscreen
2112023, 2251 \What is Normalization in DBMS (SQL)? INF, 2NF, SNF Example @ GURUI9 = What is Normalization in DBMS (SQL)? 1NF, 2NF, 3NF Example By: Richard Peterson © Updated October 2, 2023 What is Database Normalization? Normalization is a database design technique that reduces data redundancy and eliminates undesirable characteristics like Insertion, Update and Deletion Anomalies. Normalization rules divides larger tables into smaller tables and links them using relationships. The purpose of Normalisation in SQL is to eliminate redundant (repetitive) data and ensure data is stored logically. The inventor of the relational model Edgar Codd proposed the theory of normalization of data with the introduction of the First Normal Form, and he continued to extend theory with Second and Third Normal Form. Later he joined Raymond F. Boyce to develop the theory of Boyce-Codd Normal Form. Table of Content: nips. guru8®,comaatabase-noralizaton.himl ory2112023, 2251 \What is Normalization in DBMS (SQL)? INF, 2NF, SNF Example Database Normal Forms Here is a list of Normal Forms in SQL: 1NF (First Normal Form) 2NF (Second Normal Form) 3NF (Third Normal Form) BCNF (Boyce-Codd Normal Form) ANF (Fourth Normal Form) 5NF (Fifth Normal Form) 6NF (Sixth Normal Form) . . The Theory of Data Normalization in MySQL server is still being developed further. For example, there are discussions even on 6"" Normal Form. However, in most practical applications, normalization achieves its best in 3 Normal Form. The evolution of Normalization in SQL theories is illustrated below- Ast Normal hom Normal \> Normal Form Form Database Normal Forms Boyce- codane_ > Nomal > Normal > Neral Form Form Database Normalization With Examples ntps:ww.guru8®.comvdatabase-normalizaton.himl ain2112023, 2251 \What is Normalization in DBMS (SQL)? INF, 2NF, SNF Example below. Let’s understand Normalization database with normalization example with solution: FULL NAMES PHYSICAL MOVIES RENTED SALUTATION ADDRESS Janet Jones First Street Plot Pirates of the Ms. No4 Caribbean, Clash of the Titans Robert Phil 3" Street 34 Forgetting Sarah Mr. Marshal, Daddy’s Little Girls Robert Phil 5" Avenue Clash of the Titans | Mr. Here you see Movies Rented column has multiple values. Now let’s move into 1st Normal Forms: 1NF (First Normal Form) Rules * Each table cell should contain a single value. © Each record needs to be unique. The above table in 1NF- 1NF Example FULL NAMES PHYSICAL MOVIES RENTED SALUTATION ADDRESS Janet Jones First Street Plot Pirates of the Ms. No4 Caribbean Janet Jones First Street Plot. | Clash of the Titans | Ms. No4 Robert Phil 3" Street 34 Forgetting Sarah Mr. Marshal Robert Phil 3" Street 34 Daddy’s Little Girls | Mr. ntps:ww.guru8®.comvdatabase-normalizaton.himl a32112023, 2251 \What is Normalization in DBMS (SQL)? INF, 2NF, SNF Example Before we proceed let’s understand a few things — What is a KEY in SQL AKEY in SQLis a value used to identify records in a table uniquely. An SQL KEY is a single column or combination of multiple columns used to uniquely identify rows or tuples in the table. SQL Key is used to identify duplicate information, and it also helps establish a relationship between multiple tables in the database. Note: Columns in a table that are NOT used to identify a record uniquely are called non-key columns. What is a Primary Key? Prinary Kes Primary Key in DBMS Aprimary is a single column value used to identify a database record uniquely. It has following attributes © Aprimary key cannot be NULL * Aprimary key value must be unique ¢ The primary key values should rarely be changed © The primary key must be given a value when a new record is inserted. ntps:ww.guru8®.comvdatabase-normalizaton.himl ans2112023, 2251 \What is Normalization in DBMS (SQL)? INF, 2NF, SNF Example What is Composite Key? Acomposite key is a primary key composed of multiple columns used to identify a record uniquely In our database, we have two people with the same name Robert Phil, but they live in different places. = Composite Key Robert Phil 3” Street 34 Daddy's Little Girls | Mr. Robert Phil S" avenue _) _| Clash of the Titans You need name as well Addvess to aniqnely identify a vecovd. Composite key in Database Hence, we require both Full Name and Address to identify a record uniquely. That is a composite key. Let’s move into second normal form 2NF ntps:ww.guru8®.comvdatabase-normalizaton.himl 5132ayn/2029, 2251 ‘Whats Nomalzation in DBMS (SQL)? INF, 2NF, SNF Example ¢ Rule 2- Single Column Primary Key that does not functionally dependant on any subset of candidate key relation It is clear that we can’t move forward to make our simple database in 24 Normalization form unless we partition the table above. MEMBERSHIP ID FULL NAMES PHYSICAL ADDRESS SALUTATION 1 Janet Jones First Street PlotNo4 | Ms. 2 Robert Phil 3 Street 34 Mr. 3 Robert Phil S™ Avenue Mr. (Mengeesaie i | Movies rewteD fx | Piratesof the Caribbean ] 1 Clash of the Titans [fz __ Forgetting Sarah Marshal | 2 Daddy's Little Girls EB | Clash of the Titans | We have divided our 1NF table into two tables viz. Table 1 and Table2. Table 1 contains member information. Table 2 contains information on movies rented. We have introduced a new column called Membership_id which is the primary key for table 1. Records can be uniquely identified in Table 1 using membership id Database - Foreign Key In Table 2, Membership_ID is the Foreign Key [Mewpersae ip | Movies RENTED fx rates of the Caribbean ] 1 Clash of the Titans iz |_ Forgetting Sarah Marshal [2 Daddy's Little Girls EB | Clash of the Titans | ntps:ww.guru8®.comvdatabase-normalizaton.himl ens2112023, 2251 \What is Normalization in DBMS (SQL)? INF, 2NF, SNF Example Foreign Keg Foreign Key in DBMS Foreign Key references the primary key of another Table! It helps connect your Tables © A foreign key can have a different name from its primary key It ensures rows in one table have corresponding rows in another © Unlike the Primary key, they do not have to be unique. Most often they aren’t © Foreign keys can be null even though primary keys can not ntps:ww.guru8®.comvdatabase-normalizaton.himl 732112023, 2251 \What is Normalization in DBMS (SQL)? INF, 2NF, 3NF Example o& Foreign Key MOVIES RENTED Pirates of the Caribbean Clash of the Titans Forgetting Sarah Marshal Daddy's Little Girls Clash of the Titans MEMBERSHIP ID Foreign Key references Primary Key Foreign Key can only have values present in primary key It could have a name other than that of Primary Key oS Primary Key MEMBERSHIP ID FULL NAMES PHYSICAL ADDRESS SALUTATION Janet Jones First Street PlotNo4 | Ms. Robert Phil 3° Street 34 Mr. 3 Robert Phil 5” Avenue Mr. Why do you need a foreign key? Suppose, a novice inserts a record in Table B such as Insert a vecord in Table 2 wheve Member [D> =10! MEMBERSHIP ID MOVIES RENTED 101 Mission impos: But Membership [D> 101 is not present in Table { MEMBERSHIP ID FULL NAMES PHYSICAL ADDRESS SALUTATION First Street Plot No 4 2 Robert Phil | 39 Street 34 Mr. | 5™ Avenue Mr. hntps:www.guru99,comidatabase-normalization.himl 832112023, 2251 \What is Normalization in DBMS (SQL)? INF, 2NF, SNF Example You will only be able to insert values into your foreign key that exist in the unique key in the parent table. This helps in referential integrity. The above problem can be overcome by declaring membership id from Table2 as foreign key of membership id from Table1 Now, if somebody tries to insert a value in the membership id field that does not exist in the parent table, an error will be shown! What are transitive functional dependencies? Atransitive functional dependency is when changing a non-key column, might cause any of the other non-key columns to change Consider the table 1. Changing the non-key column Full Name may change Salutation. MEMBERSHIP 1D FULL NAMES. PHYSICAL ADDRESS ‘SALUTATION 1 Janet J irst Street PlotNo4 | Ms. 2 3” Street 34 Me 3 5” Avenue Mr. Way Change Change in Name’ ee Salichation Let’s move into 3NF ntps:ww.guru8®.comvdatabase-normalizaton.himl ons2ayn/2029, 2251 ‘Whats Nomalzation in DBMS (SQL)? INF, 2NF, SNF Example © Rule 1- Bein 2NF © Rule 2- Has no transitive functional dependencies To move our 2NF table into 3NF, we again need to again divide our table. 3NF Example Below is a 3NF example in SQL database: MEMBERSHIP ID FULL NAMES PHYSICAL ADDRESS SALUTATION ID 1 “lanetlones | FirstStreetPlotNoé 2 2 Rol 1 3 Robert Phil 5® Avenue 1 (MENaeRsiie | Movies RENTED ‘1 Piratesof the Caribbean 1 Clash of the Titans Bz Forgetting Saran Maishal 2 Daddy's Little Girs 3 Clash of the Titans SALUTATION ID SALUTATION, a1 SS 2 Ms. 3 Mrs. 4 | Dr. We have again divided our tables and created a new table which stores Salutations. There are no transitive functional dependencies, and hence our table is in 3NF In Table 3 Salutation ID is primary key, and in Table 1 Salutation ID is foreign to primary key in Table 3 Now our little example is at a level that cannot further be decomposed to attain higher normal form types of normalization in DBMS. In fact, it is already in higher normalization forms. Separate efforts for moving into next levels of normalizing data are normally needed in complex databases. However, we will be discussing ntps:ww.guru8®.comvdatabase-normalizaton.himl 101132ayn/2029, 2251 ‘Whats Nomalzation in DBMS (SQL)? INF, 2NF, SNF Example Even when a database is in 3" Normal Form, still there would be anomalies resulted if it has more than one Candidate Key. Sometimes is BCNF is also referred as 3.5 Normal Form, 4NF (Fourth Normal Form) Rules If no database table instance contains two or more, independent and multivalued data describing the relevant entity, then itis in 4° Normal Form. 5NF (Fifth Normal Form) Rules A table is in 5t* Normal Form only if it is in 4NF and it cannot be decomposed into any number of smaller tables without loss of data. 6NF (Sixth Normal Form) Proposed 6" Normal Form is not standardized, yet however, it is being discussed by database experts for some time. Hopefully, we would have a clear & standardized definition for 6" Normal Form in the near future... That’s all to SQL Normalization!!! Summary Database designing is critical to the successful implementation of a database management system that meets the data requirements of an enterprise system. Normalization in DBMS is a process which helps produce database systems that are cost-effective and have better security models. Functional dependencies are a very important component of the normalize data process Most database systems are normalized database up to the third normal forms in DBMS. . . ntps:ww.guru8®.comvdatabase-normalizaton.himl ss
You might also like
What Is Normalization in DBMS (SQL) - 1NF, 2NF, 3NF, BCNF Database With Example
PDF
No ratings yet
What Is Normalization in DBMS (SQL) - 1NF, 2NF, 3NF, BCNF Database With Example
8 pages
Normalization Practice Questions
PDF
No ratings yet
Normalization Practice Questions
11 pages
Prepared By:: Biplap Bhattarai
PDF
No ratings yet
Prepared By:: Biplap Bhattarai
27 pages
Normalization
PDF
No ratings yet
Normalization
20 pages
What Is Normalization in DBMS
PDF
No ratings yet
What Is Normalization in DBMS
9 pages
DBMS Unit 5
PDF
No ratings yet
DBMS Unit 5
28 pages
Normalization
PDF
No ratings yet
Normalization
25 pages
Unit 1dbms Merged
PDF
No ratings yet
Unit 1dbms Merged
30 pages
Week 6
PDF
No ratings yet
Week 6
9 pages
DMBS Unit 2
PDF
No ratings yet
DMBS Unit 2
16 pages
Normalization
PDF
No ratings yet
Normalization
17 pages
Wa0001.
PDF
No ratings yet
Wa0001.
32 pages
Database Normalization
PDF
No ratings yet
Database Normalization
8 pages
Week 3 Dbms
PDF
No ratings yet
Week 3 Dbms
6 pages
Normalization Notes
PDF
No ratings yet
Normalization Notes
7 pages
Normalization in Database Management System
PDF
No ratings yet
Normalization in Database Management System
23 pages
WWW Tutorialspoint Com Normal Forms in Dbms
PDF
No ratings yet
WWW Tutorialspoint Com Normal Forms in Dbms
6 pages
Normalization With Examples
PDF
No ratings yet
Normalization With Examples
21 pages
Normalization Lec4
PDF
No ratings yet
Normalization Lec4
29 pages
ASSIGNMENT NORMALIZATION - Phoenix
PDF
No ratings yet
ASSIGNMENT NORMALIZATION - Phoenix
8 pages
Normalization
PDF
No ratings yet
Normalization
7 pages
Topic 2 - Normalization Notes
PDF
No ratings yet
Topic 2 - Normalization Notes
5 pages
Unit Ii Normalization - Codds Rules
PDF
No ratings yet
Unit Ii Normalization - Codds Rules
30 pages
Chapter 5-T323 Introduction To The Relational Database
PDF
No ratings yet
Chapter 5-T323 Introduction To The Relational Database
37 pages
Dbms Theory Notes Unit IV
PDF
No ratings yet
Dbms Theory Notes Unit IV
73 pages
Normalization Detail
PDF
No ratings yet
Normalization Detail
9 pages
Normalization & Types of Normalization
PDF
No ratings yet
Normalization & Types of Normalization
23 pages
Database Techniques DB Normalization
PDF
No ratings yet
Database Techniques DB Normalization
37 pages
Normal Form
PDF
No ratings yet
Normal Form
24 pages
Normalization
PDF
No ratings yet
Normalization
34 pages
What Is Normalization in DBMS
PDF
No ratings yet
What Is Normalization in DBMS
11 pages
Normalization
PDF
No ratings yet
Normalization
13 pages
Unit 4
PDF
No ratings yet
Unit 4
19 pages
Topic6 Normalization Updated
PDF
No ratings yet
Topic6 Normalization Updated
14 pages
FDBMS Unit 4, 5
PDF
No ratings yet
FDBMS Unit 4, 5
35 pages
Normalization Lesson
PDF
No ratings yet
Normalization Lesson
13 pages
Database Normalization Tutorial
PDF
No ratings yet
Database Normalization Tutorial
14 pages
Normalization in DBMS
PDF
No ratings yet
Normalization in DBMS
13 pages
Normalization Dbms
PDF
No ratings yet
Normalization Dbms
23 pages
What Is Normalization ? Why Should We Use It?
PDF
No ratings yet
What Is Normalization ? Why Should We Use It?
9 pages
What Is Normalization? Why Should We Use It?
PDF
No ratings yet
What Is Normalization? Why Should We Use It?
4 pages
WWW
PDF
No ratings yet
WWW
13 pages
Normalisation
PDF
No ratings yet
Normalisation
23 pages
DBMS Normalization
PDF
No ratings yet
DBMS Normalization
53 pages
Normalization in DBMS
PDF
No ratings yet
Normalization in DBMS
7 pages
Database Normalization: MIS 520 - Database Theory Fall 2001 (Day) Lecture 4/5/6
PDF
No ratings yet
Database Normalization: MIS 520 - Database Theory Fall 2001 (Day) Lecture 4/5/6
32 pages
Chapter 6 - Normalization of Database Tables
PDF
No ratings yet
Chapter 6 - Normalization of Database Tables
23 pages
2.chapter 5
PDF
No ratings yet
2.chapter 5
21 pages
Dbms Chapter 3
PDF
No ratings yet
Dbms Chapter 3
47 pages
What Is Database Normalization
PDF
No ratings yet
What Is Database Normalization
12 pages
4.what Is Normalization PDF
PDF
No ratings yet
4.what Is Normalization PDF
9 pages
Database Normalization
PDF
No ratings yet
Database Normalization
7 pages
SQ L Normalization
PDF
100% (1)
SQ L Normalization
9 pages
Normalization: Normalization Is A Systematic Way of Ensuring That A Database Structure Is Suitable For
PDF
No ratings yet
Normalization: Normalization Is A Systematic Way of Ensuring That A Database Structure Is Suitable For
6 pages
Normal
PDF
No ratings yet
Normal
10 pages
Normal Form (1NF)
PDF
No ratings yet
Normal Form (1NF)
3 pages
Basic Principles of Database Normalization
PDF
No ratings yet
Basic Principles of Database Normalization
7 pages