SlideShare a Scribd company logo
DATABASE
NORMALIZATION
Normalization forms
Normalization example
Coming UP
Normalization forms
1st Normal Form
2nd Normal Form
3rd Normal Form
Boyce-Codd Normal Form
4th Normal Form
5th Normal Form
6th Normal Form
Key terms
Column – Attribute
Row – Tuple
Table – Relation
There are further enhancements to theory of normalization
and it is still being developed. There is even 6th normal
form but in any practical scenario, normalization achieves
its best shape in 3rd Normal form.
Entity – Any real world object that makes sense
Normalization example
Let us look at a library table that maintains all the books they rent
out in one single table:
Now let us push this data from various normal forms and see how we
can refine the data.
The rules of the first normal form are:
Each table cell should contain a single/atomic value
Every record in the table must be unique
1NF (First Normal Form)
Let us first convert the Books_Main_Table into 1NF
As per the 1NF rules, our Books Main Table looks good. Before we
proceed with 2NF and 3NF, we need to understand key columns.
Key / non-key columns
Any column (or group of columns) in a table which can uniquely identify each
row is known as key column. For example:
Phone number
Email ID
Student Roll Number
Employee ID
These are some columns which will always remain unique to every record inside
the table.
Such columns are known as key columns inside the table. Any column apart
from key columns is known as non-key column.
Primary key
A primary key is a single column value which uniquely identifies each
record in a table. In RDBMS, primary key must satisfy below:
Primary key must be unique
Primary key cannot be null
Every record will have primary key value
Composite Key
Sometimes its hard to define unique records with one single column. In
such cases, we can have two or more columns that uniquely identify each
record in a table. Such columns are known as composite key. For
example:
Name + Address
First Name + DOB + Father Name
Now that we know about key / non-key columns, let us move to 2NF.
2NF (Second Normal Form)
The rules of the second normal form are:
Table must be in 1NF
Every non-key attribute must be fully dependent on key attributes
We see that our Books_Main_Table does not have any primary key, in such
cases, we will have to introduce a new key column like Membership ID.
To make Books_Main_Table into 2NF, we need to see how columns are
closely related:
Membership ID has a salutation, name and address
Membership ID has books issued on their name
With this logic in mind, we will have to divide our Books_Main_Table
into two table:
Foreign Key
If you see the above tables, we have Membership ID in both tables
but in Membership_Details_table, it is a primary key column and
in Books_Issued_table, it is a non-key column.
Till now we have seen Primary key and composite key. A foreign
key refers to a primary key column of another table. This helps in
connecting two tables (and defines a relation between two tables).
A foreign key must satisfy below:
Foreign key column name can be different than primary key
column name
Unlike primary key, then need not be unique (see
Books_Issued_Table above)
Foreign key column can be null even though primary key
column cannot
Reason for Foreign key
When a user tries to insert a record into Books_Issued_Table
and if there is no membership ID exists in
Membership_Details_Table, it will be rejected. This way, we
maintain data integrity in RDBMS.
If there is no record with Membership ID in the parent table,
it will be rejected and database will throw an error.
3NF (Third Normal Form)
The rules of the third normal form are:
Data must be in 2NF
No transitive functional dependencies
What is transitive dependency?
In simple terms, if changing a non-key column causes any other non-key
column to change, then its called as transitive dependency.
In our example, if we change Full Name of the customer, it
might change Salutation
Final 3NF Tables
To move the Membership_Details_Table into 3NF, we need to further
divide the table into below:
We have divided the Membership_Details_Table
into a new Salutation_table.
Assignment
If you see the Books_Issued_Table, it still does not have
a key column. What do you think should be the key
column for the Books_Issued_Table? Or do we need to
introduce a new column?
Courses | Projects | Bootcamps

More Related Content

What's hot

Normalization in DBMS
Normalization in DBMSNormalization in DBMS
Normalization in DBMS
Prateek Parimal
 
Normalization in DBMS
Normalization in DBMSNormalization in DBMS
Normalization in DBMS
Hitesh Mohapatra
 
joins in database
 joins in database joins in database
joins in database
Sultan Arshad
 
Normalization
NormalizationNormalization
Normalization
momo2187
 
Normalization PRESENTATION
Normalization PRESENTATIONNormalization PRESENTATION
Normalization PRESENTATION
bit allahabad
 
Normalization in DBMS
Normalization in DBMSNormalization in DBMS
Normalization in DBMS
Prateek Parimal
 
Database Normalization 1NF, 2NF, 3NF, BCNF, 4NF, 5NF
Database Normalization 1NF, 2NF, 3NF, BCNF, 4NF, 5NFDatabase Normalization 1NF, 2NF, 3NF, BCNF, 4NF, 5NF
Database Normalization 1NF, 2NF, 3NF, BCNF, 4NF, 5NF
Oum Saokosal
 
Relational model
Relational modelRelational model
Relational model
Dabbal Singh Mahara
 
database Normalization
database Normalizationdatabase Normalization
database Normalization
Harsiddhi Thakkar
 
Normalization
NormalizationNormalization
Normalization
Wangu Thupa
 
Database : Relational Data Model
Database : Relational Data ModelDatabase : Relational Data Model
Database : Relational Data Model
Smriti Jain
 
2. Entity Relationship Model in DBMS
2. Entity Relationship Model in DBMS2. Entity Relationship Model in DBMS
2. Entity Relationship Model in DBMSkoolkampus
 
12. Indexing and Hashing in DBMS
12. Indexing and Hashing in DBMS12. Indexing and Hashing in DBMS
12. Indexing and Hashing in DBMSkoolkampus
 
DML Commands
DML CommandsDML Commands
Codd's rules
Codd's rulesCodd's rules
Codd's rulesMohd Arif
 
Joins in dbms and types
Joins in dbms and typesJoins in dbms and types
Joins in dbms and types
university of Gujrat, pakistan
 
Integrity Constraints
Integrity ConstraintsIntegrity Constraints
Integrity Constraints
madhav bansal
 
Database Concept - Normalization (1NF, 2NF, 3NF)
Database Concept - Normalization (1NF, 2NF, 3NF)Database Concept - Normalization (1NF, 2NF, 3NF)
Database Concept - Normalization (1NF, 2NF, 3NF)
Oum Saokosal
 
DATABASE CONSTRAINTS
DATABASE CONSTRAINTSDATABASE CONSTRAINTS
DATABASE CONSTRAINTS
sunanditaAnand
 
Functional dependencies and normalization
Functional dependencies and normalizationFunctional dependencies and normalization
Functional dependencies and normalizationdaxesh chauhan
 

What's hot (20)

Normalization in DBMS
Normalization in DBMSNormalization in DBMS
Normalization in DBMS
 
Normalization in DBMS
Normalization in DBMSNormalization in DBMS
Normalization in DBMS
 
joins in database
 joins in database joins in database
joins in database
 
Normalization
NormalizationNormalization
Normalization
 
Normalization PRESENTATION
Normalization PRESENTATIONNormalization PRESENTATION
Normalization PRESENTATION
 
Normalization in DBMS
Normalization in DBMSNormalization in DBMS
Normalization in DBMS
 
Database Normalization 1NF, 2NF, 3NF, BCNF, 4NF, 5NF
Database Normalization 1NF, 2NF, 3NF, BCNF, 4NF, 5NFDatabase Normalization 1NF, 2NF, 3NF, BCNF, 4NF, 5NF
Database Normalization 1NF, 2NF, 3NF, BCNF, 4NF, 5NF
 
Relational model
Relational modelRelational model
Relational model
 
database Normalization
database Normalizationdatabase Normalization
database Normalization
 
Normalization
NormalizationNormalization
Normalization
 
Database : Relational Data Model
Database : Relational Data ModelDatabase : Relational Data Model
Database : Relational Data Model
 
2. Entity Relationship Model in DBMS
2. Entity Relationship Model in DBMS2. Entity Relationship Model in DBMS
2. Entity Relationship Model in DBMS
 
12. Indexing and Hashing in DBMS
12. Indexing and Hashing in DBMS12. Indexing and Hashing in DBMS
12. Indexing and Hashing in DBMS
 
DML Commands
DML CommandsDML Commands
DML Commands
 
Codd's rules
Codd's rulesCodd's rules
Codd's rules
 
Joins in dbms and types
Joins in dbms and typesJoins in dbms and types
Joins in dbms and types
 
Integrity Constraints
Integrity ConstraintsIntegrity Constraints
Integrity Constraints
 
Database Concept - Normalization (1NF, 2NF, 3NF)
Database Concept - Normalization (1NF, 2NF, 3NF)Database Concept - Normalization (1NF, 2NF, 3NF)
Database Concept - Normalization (1NF, 2NF, 3NF)
 
DATABASE CONSTRAINTS
DATABASE CONSTRAINTSDATABASE CONSTRAINTS
DATABASE CONSTRAINTS
 
Functional dependencies and normalization
Functional dependencies and normalizationFunctional dependencies and normalization
Functional dependencies and normalization
 

Similar to Database Normalization

Data normailazation
Data normailazationData normailazation
Data normailazation
Lalit Kale
 
What is Database NormalizationExplain the guidelines for ensuring t.pdf
What is Database NormalizationExplain the guidelines for ensuring t.pdfWhat is Database NormalizationExplain the guidelines for ensuring t.pdf
What is Database NormalizationExplain the guidelines for ensuring t.pdf
arjunstores123
 
Database normalization
Database normalizationDatabase normalization
Database normalizationJignesh Jain
 
B & c
B & cB & c
DATABASE CONCEPTS AND PRACTICAL EXAMPLES
DATABASE CONCEPTS AND PRACTICAL EXAMPLESDATABASE CONCEPTS AND PRACTICAL EXAMPLES
DATABASE CONCEPTS AND PRACTICAL EXAMPLES
NathRam2
 
1683368767418684.pdf
1683368767418684.pdf1683368767418684.pdf
1683368767418684.pdf
Janoakre
 
Key,ID Field and Tables Relationship
Key,ID Field and Tables Relationship Key,ID Field and Tables Relationship
Key,ID Field and Tables Relationship
ShouaQureshi
 
Normalization
NormalizationNormalization
Normalization
Prabal Chauhan
 
Advance Sqlite3
Advance Sqlite3Advance Sqlite3
Advance Sqlite3Raghu nath
 
Relational Model
Relational ModelRelational Model
Relational Model
Er. Nawaraj Bhandari
 
The Relational Model
The Relational ModelThe Relational Model
The Relational Model
Bhandari Nawaraj
 
Dbms interview questions
Dbms interview questionsDbms interview questions
Dbms interview questions
ambika93
 
Database Management Systems 4 - Normalization
Database Management Systems 4 - NormalizationDatabase Management Systems 4 - Normalization
Database Management Systems 4 - NormalizationNickkisha Farrell
 
Understanding about relational database m-square systems inc
Understanding about relational database m-square systems incUnderstanding about relational database m-square systems inc
Understanding about relational database m-square systems inc
Muthu Natarajan
 
Normalization
NormalizationNormalization
Normalization
Shakila Mahjabin
 
Database Concepts.pptx
Database Concepts.pptxDatabase Concepts.pptx
Database Concepts.pptx
DhruvSavaliya9
 
Db lec 06_new
Db lec 06_newDb lec 06_new
Db lec 06_new
Ramadan Babers, PhD
 
Dependencies in various topics like normalisation and its types
Dependencies in various topics like normalisation and its typesDependencies in various topics like normalisation and its types
Dependencies in various topics like normalisation and its types
nsrChowdary1
 
Normalization
NormalizationNormalization
Normalization
Ramesh 4
 

Similar to Database Normalization (20)

Data normailazation
Data normailazationData normailazation
Data normailazation
 
What is Database NormalizationExplain the guidelines for ensuring t.pdf
What is Database NormalizationExplain the guidelines for ensuring t.pdfWhat is Database NormalizationExplain the guidelines for ensuring t.pdf
What is Database NormalizationExplain the guidelines for ensuring t.pdf
 
Database normalization
Database normalizationDatabase normalization
Database normalization
 
B & c
B & cB & c
B & c
 
DATABASE CONCEPTS AND PRACTICAL EXAMPLES
DATABASE CONCEPTS AND PRACTICAL EXAMPLESDATABASE CONCEPTS AND PRACTICAL EXAMPLES
DATABASE CONCEPTS AND PRACTICAL EXAMPLES
 
1683368767418684.pdf
1683368767418684.pdf1683368767418684.pdf
1683368767418684.pdf
 
Key,ID Field and Tables Relationship
Key,ID Field and Tables Relationship Key,ID Field and Tables Relationship
Key,ID Field and Tables Relationship
 
Normalization
NormalizationNormalization
Normalization
 
Advance Sqlite3
Advance Sqlite3Advance Sqlite3
Advance Sqlite3
 
Relational Model
Relational ModelRelational Model
Relational Model
 
The Relational Model
The Relational ModelThe Relational Model
The Relational Model
 
Dbms interview questions
Dbms interview questionsDbms interview questions
Dbms interview questions
 
Database Management Systems 4 - Normalization
Database Management Systems 4 - NormalizationDatabase Management Systems 4 - Normalization
Database Management Systems 4 - Normalization
 
Understanding about relational database m-square systems inc
Understanding about relational database m-square systems incUnderstanding about relational database m-square systems inc
Understanding about relational database m-square systems inc
 
Normalization
NormalizationNormalization
Normalization
 
Database Concepts.pptx
Database Concepts.pptxDatabase Concepts.pptx
Database Concepts.pptx
 
Db lec 06_new
Db lec 06_newDb lec 06_new
Db lec 06_new
 
Dependencies in various topics like normalisation and its types
Dependencies in various topics like normalisation and its typesDependencies in various topics like normalisation and its types
Dependencies in various topics like normalisation and its types
 
Normalization
NormalizationNormalization
Normalization
 
Database design
Database designDatabase design
Database design
 

More from Arun Sharma

Important Linux Commands
Important Linux CommandsImportant Linux Commands
Important Linux Commands
Arun Sharma
 
Oracle Golden Gate Functions
Oracle Golden Gate FunctionsOracle Golden Gate Functions
Oracle Golden Gate Functions
Arun Sharma
 
Oracle Golden Gate Bidirectional Replication
Oracle Golden Gate Bidirectional ReplicationOracle Golden Gate Bidirectional Replication
Oracle Golden Gate Bidirectional Replication
Arun Sharma
 
Install Oracle 12c Golden Gate On Oracle Linux
Install Oracle 12c Golden Gate On Oracle LinuxInstall Oracle 12c Golden Gate On Oracle Linux
Install Oracle 12c Golden Gate On Oracle Linux
Arun Sharma
 
Configure Golden Gate Initial Load and Change Sync
Configure Golden Gate Initial Load and Change SyncConfigure Golden Gate Initial Load and Change Sync
Configure Golden Gate Initial Load and Change Sync
Arun Sharma
 
Oracle TKPROF Utility
Oracle TKPROF UtilityOracle TKPROF Utility
Oracle TKPROF Utility
Arun Sharma
 
Oracle Segment Advisor
Oracle Segment AdvisorOracle Segment Advisor
Oracle Segment Advisor
Arun Sharma
 
Oracle 11g Installation With ASM and Data Guard Setup
Oracle 11g Installation With ASM and Data Guard SetupOracle 11g Installation With ASM and Data Guard Setup
Oracle 11g Installation With ASM and Data Guard Setup
Arun Sharma
 
Oracle 11g to 12c Upgrade With Data Guard and ASM
Oracle 11g to 12c  Upgrade With Data Guard and ASMOracle 11g to 12c  Upgrade With Data Guard and ASM
Oracle 11g to 12c Upgrade With Data Guard and ASM
Arun Sharma
 
Oracle 11g to 12c Rolling Upgrade
Oracle 11g to 12c Rolling UpgradeOracle 11g to 12c Rolling Upgrade
Oracle 11g to 12c Rolling Upgrade
Arun Sharma
 
Convert Physical Standby Into Logical Standby
Convert Physical Standby Into Logical StandbyConvert Physical Standby Into Logical Standby
Convert Physical Standby Into Logical Standby
Arun Sharma
 
Enable Fast Start Failover Data Guard Broker
Enable Fast Start Failover Data Guard BrokerEnable Fast Start Failover Data Guard Broker
Enable Fast Start Failover Data Guard Broker
Arun Sharma
 
Data Guard Broker Failover
Data Guard Broker FailoverData Guard Broker Failover
Data Guard Broker Failover
Arun Sharma
 
Oracle Data Guard Physical Standby Configuration
Oracle Data Guard Physical Standby ConfigurationOracle Data Guard Physical Standby Configuration
Oracle Data Guard Physical Standby Configuration
Arun Sharma
 
Schedule RMAN Backups On Windows
Schedule RMAN Backups On WindowsSchedule RMAN Backups On Windows
Schedule RMAN Backups On Windows
Arun Sharma
 
RMAN Backup Compression Types
RMAN Backup Compression TypesRMAN Backup Compression Types
RMAN Backup Compression Types
Arun Sharma
 
Scheduling Jobs With DBMA_Scheduler
Scheduling Jobs With DBMA_SchedulerScheduling Jobs With DBMA_Scheduler
Scheduling Jobs With DBMA_Scheduler
Arun Sharma
 
Oracle User Management
Oracle User ManagementOracle User Management
Oracle User Management
Arun Sharma
 
Create Directory Under ASM Diskgroup
Create Directory Under ASM DiskgroupCreate Directory Under ASM Diskgroup
Create Directory Under ASM Diskgroup
Arun Sharma
 
Create Diskgroup Sqlplus Command
Create Diskgroup Sqlplus CommandCreate Diskgroup Sqlplus Command
Create Diskgroup Sqlplus Command
Arun Sharma
 

More from Arun Sharma (20)

Important Linux Commands
Important Linux CommandsImportant Linux Commands
Important Linux Commands
 
Oracle Golden Gate Functions
Oracle Golden Gate FunctionsOracle Golden Gate Functions
Oracle Golden Gate Functions
 
Oracle Golden Gate Bidirectional Replication
Oracle Golden Gate Bidirectional ReplicationOracle Golden Gate Bidirectional Replication
Oracle Golden Gate Bidirectional Replication
 
Install Oracle 12c Golden Gate On Oracle Linux
Install Oracle 12c Golden Gate On Oracle LinuxInstall Oracle 12c Golden Gate On Oracle Linux
Install Oracle 12c Golden Gate On Oracle Linux
 
Configure Golden Gate Initial Load and Change Sync
Configure Golden Gate Initial Load and Change SyncConfigure Golden Gate Initial Load and Change Sync
Configure Golden Gate Initial Load and Change Sync
 
Oracle TKPROF Utility
Oracle TKPROF UtilityOracle TKPROF Utility
Oracle TKPROF Utility
 
Oracle Segment Advisor
Oracle Segment AdvisorOracle Segment Advisor
Oracle Segment Advisor
 
Oracle 11g Installation With ASM and Data Guard Setup
Oracle 11g Installation With ASM and Data Guard SetupOracle 11g Installation With ASM and Data Guard Setup
Oracle 11g Installation With ASM and Data Guard Setup
 
Oracle 11g to 12c Upgrade With Data Guard and ASM
Oracle 11g to 12c  Upgrade With Data Guard and ASMOracle 11g to 12c  Upgrade With Data Guard and ASM
Oracle 11g to 12c Upgrade With Data Guard and ASM
 
Oracle 11g to 12c Rolling Upgrade
Oracle 11g to 12c Rolling UpgradeOracle 11g to 12c Rolling Upgrade
Oracle 11g to 12c Rolling Upgrade
 
Convert Physical Standby Into Logical Standby
Convert Physical Standby Into Logical StandbyConvert Physical Standby Into Logical Standby
Convert Physical Standby Into Logical Standby
 
Enable Fast Start Failover Data Guard Broker
Enable Fast Start Failover Data Guard BrokerEnable Fast Start Failover Data Guard Broker
Enable Fast Start Failover Data Guard Broker
 
Data Guard Broker Failover
Data Guard Broker FailoverData Guard Broker Failover
Data Guard Broker Failover
 
Oracle Data Guard Physical Standby Configuration
Oracle Data Guard Physical Standby ConfigurationOracle Data Guard Physical Standby Configuration
Oracle Data Guard Physical Standby Configuration
 
Schedule RMAN Backups On Windows
Schedule RMAN Backups On WindowsSchedule RMAN Backups On Windows
Schedule RMAN Backups On Windows
 
RMAN Backup Compression Types
RMAN Backup Compression TypesRMAN Backup Compression Types
RMAN Backup Compression Types
 
Scheduling Jobs With DBMA_Scheduler
Scheduling Jobs With DBMA_SchedulerScheduling Jobs With DBMA_Scheduler
Scheduling Jobs With DBMA_Scheduler
 
Oracle User Management
Oracle User ManagementOracle User Management
Oracle User Management
 
Create Directory Under ASM Diskgroup
Create Directory Under ASM DiskgroupCreate Directory Under ASM Diskgroup
Create Directory Under ASM Diskgroup
 
Create Diskgroup Sqlplus Command
Create Diskgroup Sqlplus CommandCreate Diskgroup Sqlplus Command
Create Diskgroup Sqlplus Command
 

Recently uploaded

top nidhi software solution freedownload
top nidhi software solution freedownloadtop nidhi software solution freedownload
top nidhi software solution freedownload
vrstrong314
 
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data AnalysisProviding Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
Globus
 
Quarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden ExtensionsQuarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden Extensions
Max Andersen
 
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
Juraj Vysvader
 
Prosigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology SolutionsProsigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology Solutions
Prosigns
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
Globus
 
SOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar Research Team: Latest Activities of IntelBrokerSOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar
 
Visitor Management System in India- Vizman.app
Visitor Management System in India- Vizman.appVisitor Management System in India- Vizman.app
Visitor Management System in India- Vizman.app
NaapbooksPrivateLimi
 
Vitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume MontevideoVitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume Montevideo
Vitthal Shirke
 
BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024
Ortus Solutions, Corp
 
Large Language Models and the End of Programming
Large Language Models and the End of ProgrammingLarge Language Models and the End of Programming
Large Language Models and the End of Programming
Matt Welsh
 
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoamOpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
takuyayamamoto1800
 
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Shahin Sheidaei
 
Multiple Your Crypto Portfolio with the Innovative Features of Advanced Crypt...
Multiple Your Crypto Portfolio with the Innovative Features of Advanced Crypt...Multiple Your Crypto Portfolio with the Innovative Features of Advanced Crypt...
Multiple Your Crypto Portfolio with the Innovative Features of Advanced Crypt...
Hivelance Technology
 
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus
 
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdfDominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
AMB-Review
 
How Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptxHow Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptx
wottaspaceseo
 
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Globus
 
Into the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdfInto the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdf
Ortus Solutions, Corp
 

Recently uploaded (20)

top nidhi software solution freedownload
top nidhi software solution freedownloadtop nidhi software solution freedownload
top nidhi software solution freedownload
 
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data AnalysisProviding Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
 
Quarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden ExtensionsQuarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden Extensions
 
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
 
Prosigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology SolutionsProsigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology Solutions
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
 
SOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar Research Team: Latest Activities of IntelBrokerSOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar Research Team: Latest Activities of IntelBroker
 
Visitor Management System in India- Vizman.app
Visitor Management System in India- Vizman.appVisitor Management System in India- Vizman.app
Visitor Management System in India- Vizman.app
 
Vitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume MontevideoVitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume Montevideo
 
BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024
 
Large Language Models and the End of Programming
Large Language Models and the End of ProgrammingLarge Language Models and the End of Programming
Large Language Models and the End of Programming
 
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoamOpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
 
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
 
Multiple Your Crypto Portfolio with the Innovative Features of Advanced Crypt...
Multiple Your Crypto Portfolio with the Innovative Features of Advanced Crypt...Multiple Your Crypto Portfolio with the Innovative Features of Advanced Crypt...
Multiple Your Crypto Portfolio with the Innovative Features of Advanced Crypt...
 
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
 
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdfDominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
 
How Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptxHow Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptx
 
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
 
Into the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdfInto the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdf
 

Database Normalization

  • 3. Normalization forms 1st Normal Form 2nd Normal Form 3rd Normal Form Boyce-Codd Normal Form 4th Normal Form 5th Normal Form 6th Normal Form
  • 4. Key terms Column – Attribute Row – Tuple Table – Relation There are further enhancements to theory of normalization and it is still being developed. There is even 6th normal form but in any practical scenario, normalization achieves its best shape in 3rd Normal form. Entity – Any real world object that makes sense
  • 5. Normalization example Let us look at a library table that maintains all the books they rent out in one single table: Now let us push this data from various normal forms and see how we can refine the data.
  • 6. The rules of the first normal form are: Each table cell should contain a single/atomic value Every record in the table must be unique 1NF (First Normal Form) Let us first convert the Books_Main_Table into 1NF
  • 7. As per the 1NF rules, our Books Main Table looks good. Before we proceed with 2NF and 3NF, we need to understand key columns.
  • 8. Key / non-key columns Any column (or group of columns) in a table which can uniquely identify each row is known as key column. For example: Phone number Email ID Student Roll Number Employee ID These are some columns which will always remain unique to every record inside the table. Such columns are known as key columns inside the table. Any column apart from key columns is known as non-key column.
  • 9. Primary key A primary key is a single column value which uniquely identifies each record in a table. In RDBMS, primary key must satisfy below: Primary key must be unique Primary key cannot be null Every record will have primary key value
  • 10. Composite Key Sometimes its hard to define unique records with one single column. In such cases, we can have two or more columns that uniquely identify each record in a table. Such columns are known as composite key. For example: Name + Address First Name + DOB + Father Name Now that we know about key / non-key columns, let us move to 2NF.
  • 11. 2NF (Second Normal Form) The rules of the second normal form are: Table must be in 1NF Every non-key attribute must be fully dependent on key attributes We see that our Books_Main_Table does not have any primary key, in such cases, we will have to introduce a new key column like Membership ID. To make Books_Main_Table into 2NF, we need to see how columns are closely related: Membership ID has a salutation, name and address Membership ID has books issued on their name
  • 12. With this logic in mind, we will have to divide our Books_Main_Table into two table:
  • 13. Foreign Key If you see the above tables, we have Membership ID in both tables but in Membership_Details_table, it is a primary key column and in Books_Issued_table, it is a non-key column. Till now we have seen Primary key and composite key. A foreign key refers to a primary key column of another table. This helps in connecting two tables (and defines a relation between two tables). A foreign key must satisfy below: Foreign key column name can be different than primary key column name Unlike primary key, then need not be unique (see Books_Issued_Table above)
  • 14. Foreign key column can be null even though primary key column cannot
  • 15. Reason for Foreign key When a user tries to insert a record into Books_Issued_Table and if there is no membership ID exists in Membership_Details_Table, it will be rejected. This way, we maintain data integrity in RDBMS. If there is no record with Membership ID in the parent table, it will be rejected and database will throw an error.
  • 16. 3NF (Third Normal Form) The rules of the third normal form are: Data must be in 2NF No transitive functional dependencies What is transitive dependency? In simple terms, if changing a non-key column causes any other non-key column to change, then its called as transitive dependency.
  • 17. In our example, if we change Full Name of the customer, it might change Salutation
  • 18. Final 3NF Tables To move the Membership_Details_Table into 3NF, we need to further divide the table into below:
  • 19.
  • 20. We have divided the Membership_Details_Table into a new Salutation_table.
  • 21. Assignment If you see the Books_Issued_Table, it still does not have a key column. What do you think should be the key column for the Books_Issued_Table? Or do we need to introduce a new column?
  • 22. Courses | Projects | Bootcamps