SlideShare a Scribd company logo
Normalization
1. Definition
▪ The theory of relational databases includes some wisdom about what is
and what is not good database design. These notions are expressed in
terms of restrictions, each of which excludes certain undesirable properties
from database designs. These sets of restrictions are called normal forms.
And normalization is the name given to the process of creating a database
design that does not violate them.
▪ A logical design method:
-- which minimizes data redundancy and reduces design flaws.
• Consists of applying various “normal” forms to the database design.
• The normal forms break down large tables into smaller subsets.
Normalization
2. Data Redundancy or Duplication
▪ Department name and manager are duplicated for all employees in the
department.
If redundancy exists then this can cause problems during normal
database operations:
• When data is inserted the database the data must be duplicated where ever
redundant versions of that data exists.
• When data is updated, all redundant data must be simultaneously updated to
reflect that change.

Consequences of redundancy
•
•
•
•

Wasted space
Potential performance cost
Potential inconsistency
Inability to represent data
Normalization
3. Anomalies
Insertion anomalies
If a new employee is added to deptid 2, all the info about the department
(name & manager) has to be re-input.
A new department, say it, can be added only when there exists an
employee for the new department.

Deletion anomalies
If the last employee from a department is deleted, then details of that
department disappear from the database.
Update anomalies
If the sales manager of Jones is replaced by Smith, all the records for
employees in sales department must be modified.
Normalization
4. Benefits of Normalization
• Less storage space
• Quicker updates
• Less data inconsistency
• Clearer data relationships
• Easier to add data
• Flexible structure
Normal Form
1. First Normal Form - 1nf
• A relation is said to be in first normal form (1nf) if all attribute values are atomic:
no repeating group, no composite attributes, and primary key is identified.
Patient
#

Surgeon
#

Surgery date

Patient name

Patient addr

Surgeon name

Surgery

Drug admin

Side
Effects

1111

145

01-jan-95

John white

15 new st. New york, ny

Gallstones removal

Penicillin

Rash

1111

311

12-jun-95

John white

15 new st. New york, ny

Beth little
Michael diamon
d

Kidney stones removal

None

None

1234

243

05-apr-94

Mary jones

10 main st. Rye, ny

Charles field

Eye cataract removal

Tetracycline

Fever

1234

467

10-may-95

Mary jones

10 main st. Rye, ny

Patricia gold

Thrombosis removal

None

None

2345

189

08-jan-96

Charles brown

Dogwood lane harrison, ny

David rosen

Open heart surgery

Cephalosporin

None

4876

145

05-nov-95

Hal kane

55 boston post road, chester, cn

Beth little

Cholecystectomy

Demicillin

None

5123

145

10-may-95

Paul kosher

Blind brook mamaroneck, ny

Beth little

Gallstones removal

None

None

6845

243

05-apr-94

Ann hood

Hilton road larchmont, ny

Charles field

Eye cornea replacement

Tetracycline

Fever

6845

243

15-dec-84

Ann hood

Hilton road larchmont, ny

Charles field

Eye cataract removal

None

None

• All attribute values are atomic because there are no repeating group and no
composite attributes.
Normal Form
2. Second Normal Form - 2nf
Second normal form (2nf) further addresses the concept of removing duplicative data:
• A relation r is in 2nf if
(a) r is 1nf , and
(b) all non-prime attributes are fully dependent on the candidate keys.
Which is creating relationships between these new tables and their
predecessors through the use of foreign keys.
Partial dependency must be eliminated.
Break the composite primary key into two parts, each part representing a separate
table.
• A prime attribute appears in a candidate key.
• There is no partial dependency in 2nf.
Normal Form
3. Third Normal Form - 3nf
A relation is said to be in third normal form if there is no transitive functional
dependency between nonkey attributes.
• When one nonkey attribute can be determined with one or more nonkey attributes
there is said to be a transitive functional dependency.
The side effect column in the surgery table is determined by the drug administered.
• Side effect is transitively functionally dependent on drug so surgery is not 3nf.
Normal Form
4. Denormalization
Though normalization is performed to reduce or eliminate
insertion, deletion or update anomalies, a completely normalized database
may not be the most efficient or effective implementation.
“denormalization” is sometimes used to improve efficiency.
Usually driven by the need to improve query speed.
Query speed is improved at the expense of more complex or problematic
DML (data manipulation language) for updates, deletions and insertions.

More Related Content

What's hot

NoSql
NoSqlNoSql
normalization-1.pptx
normalization-1.pptxnormalization-1.pptx
normalization-1.pptx
AbhishekJohnCharan1
 
Binary search tree(bst)
Binary search tree(bst)Binary search tree(bst)
Binary search tree(bst)
Hossain Md Shakhawat
 
1.1 binary tree
1.1 binary tree1.1 binary tree
1.1 binary tree
Krish_ver2
 
Dbms anomalies
Dbms anomaliesDbms anomalies
Dbms anomalies
Zaheer Soomro
 
Trees
TreesTrees
Red black trees
Red black treesRed black trees
Red black trees
Amit Kumar Rathi
 
Normalization
NormalizationNormalization
Normalization
meet darji
 
Data abstraction in DBMS
Data abstraction in DBMSData abstraction in DBMS
Data abstraction in DBMS
Papan Sarkar
 
Fifth normal form
Fifth normal formFifth normal form
Fifth normal form
Athi Sethu
 
Ms access ppt 2017 by Gopal saha
Ms access ppt 2017 by Gopal sahaMs access ppt 2017 by Gopal saha
Ms access ppt 2017 by Gopal saha
253253
 
Single User v/s Multi User Databases
Single User v/s Multi User DatabasesSingle User v/s Multi User Databases
Single User v/s Multi User DatabasesRaminder Pal Singh
 
Functional Dependency
Functional DependencyFunctional Dependency
Functional Dependency
MANASYJAYASURYA
 
DBMS UNIT1
DBMS UNIT1DBMS UNIT1
DBMS UNIT1
CHANDRA BHUSHAN
 
Purpose of DBMS and users of DBMS
Purpose of DBMS and users of DBMSPurpose of DBMS and users of DBMS
Purpose of DBMS and users of DBMS
DharmamSavani
 
B+ trees and height balance tree
B+ trees and height balance treeB+ trees and height balance tree
B+ trees and height balance tree
Jasleen Kaur (Chandigarh University)
 
Binary tree and Binary search tree
Binary tree and Binary search treeBinary tree and Binary search tree
Binary tree and Binary search tree
Mayeesha Samiha
 
Binary tree
Binary  treeBinary  tree
Binary tree
Vanitha Chandru
 

What's hot (20)

NoSql
NoSqlNoSql
NoSql
 
normalization-1.pptx
normalization-1.pptxnormalization-1.pptx
normalization-1.pptx
 
Binary search tree(bst)
Binary search tree(bst)Binary search tree(bst)
Binary search tree(bst)
 
1.1 binary tree
1.1 binary tree1.1 binary tree
1.1 binary tree
 
Dbms anomalies
Dbms anomaliesDbms anomalies
Dbms anomalies
 
Trees
TreesTrees
Trees
 
Red black trees
Red black treesRed black trees
Red black trees
 
Normalization
NormalizationNormalization
Normalization
 
b+ tree
b+ treeb+ tree
b+ tree
 
Data abstraction in DBMS
Data abstraction in DBMSData abstraction in DBMS
Data abstraction in DBMS
 
Enhanced ER(database)
Enhanced ER(database)Enhanced ER(database)
Enhanced ER(database)
 
Fifth normal form
Fifth normal formFifth normal form
Fifth normal form
 
Ms access ppt 2017 by Gopal saha
Ms access ppt 2017 by Gopal sahaMs access ppt 2017 by Gopal saha
Ms access ppt 2017 by Gopal saha
 
Single User v/s Multi User Databases
Single User v/s Multi User DatabasesSingle User v/s Multi User Databases
Single User v/s Multi User Databases
 
Functional Dependency
Functional DependencyFunctional Dependency
Functional Dependency
 
DBMS UNIT1
DBMS UNIT1DBMS UNIT1
DBMS UNIT1
 
Purpose of DBMS and users of DBMS
Purpose of DBMS and users of DBMSPurpose of DBMS and users of DBMS
Purpose of DBMS and users of DBMS
 
B+ trees and height balance tree
B+ trees and height balance treeB+ trees and height balance tree
B+ trees and height balance tree
 
Binary tree and Binary search tree
Binary tree and Binary search treeBinary tree and Binary search tree
Binary tree and Binary search tree
 
Binary tree
Binary  treeBinary  tree
Binary tree
 

Viewers also liked

Methodology logical database design for the relational
Methodology   logical database design for the relationalMethodology   logical database design for the relational
Methodology logical database design for the relationaluniversity of the punjab
 
Entities and attributes
Entities and attributesEntities and attributes
Entities and attributes
Forrester High School
 
Methodology conceptual databases design roll no. 99 & 111
Methodology conceptual databases design roll no. 99 & 111Methodology conceptual databases design roll no. 99 & 111
Methodology conceptual databases design roll no. 99 & 111
Manoj Nolkha
 
Ism normalization pine valley 2012
Ism normalization pine valley 2012Ism normalization pine valley 2012
Ism normalization pine valley 2012
Akshit R Shah
 
Ch 6 Logical D B Design
Ch 6  Logical D B  DesignCh 6  Logical D B  Design
Ch 6 Logical D B Designguest8fdbdd
 
Logical database design and the relational model(database)
Logical database design and the relational model(database)Logical database design and the relational model(database)
Logical database design and the relational model(database)welcometofacebook
 
DBMS - Normalization
DBMS - NormalizationDBMS - Normalization
DBMS - Normalization
Jitendra Tomar
 
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
 
Hospital Management System
Hospital Management SystemHospital Management System
Hospital Management System
ĞĔŃÚĨŃĔ ĞĔŃĨÚŚ
 
Database design & Normalization (1NF, 2NF, 3NF)
Database design & Normalization (1NF, 2NF, 3NF)Database design & Normalization (1NF, 2NF, 3NF)
Database design & Normalization (1NF, 2NF, 3NF)
Jargalsaikhan Alyeksandr
 

Viewers also liked (10)

Methodology logical database design for the relational
Methodology   logical database design for the relationalMethodology   logical database design for the relational
Methodology logical database design for the relational
 
Entities and attributes
Entities and attributesEntities and attributes
Entities and attributes
 
Methodology conceptual databases design roll no. 99 & 111
Methodology conceptual databases design roll no. 99 & 111Methodology conceptual databases design roll no. 99 & 111
Methodology conceptual databases design roll no. 99 & 111
 
Ism normalization pine valley 2012
Ism normalization pine valley 2012Ism normalization pine valley 2012
Ism normalization pine valley 2012
 
Ch 6 Logical D B Design
Ch 6  Logical D B  DesignCh 6  Logical D B  Design
Ch 6 Logical D B Design
 
Logical database design and the relational model(database)
Logical database design and the relational model(database)Logical database design and the relational model(database)
Logical database design and the relational model(database)
 
DBMS - Normalization
DBMS - NormalizationDBMS - Normalization
DBMS - Normalization
 
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
 
Hospital Management System
Hospital Management SystemHospital Management System
Hospital Management System
 
Database design & Normalization (1NF, 2NF, 3NF)
Database design & Normalization (1NF, 2NF, 3NF)Database design & Normalization (1NF, 2NF, 3NF)
Database design & Normalization (1NF, 2NF, 3NF)
 

Similar to 2 normalization

Entity relationship diagram - Concept on normalization
Entity relationship diagram - Concept on normalizationEntity relationship diagram - Concept on normalization
Entity relationship diagram - Concept on normalization
Satya Pal
 
Normalization
NormalizationNormalization
Normalization
Masud Parves
 
Normalization ppt for RDBMS PPT FOR BCA and for computer science student..pptx
Normalization ppt for RDBMS PPT FOR BCA and for computer science student..pptxNormalization ppt for RDBMS PPT FOR BCA and for computer science student..pptx
Normalization ppt for RDBMS PPT FOR BCA and for computer science student..pptx
SIR RIP .NET
 
Sql server ___________session3-normailzation
Sql server  ___________session3-normailzationSql server  ___________session3-normailzation
Sql server ___________session3-normailzation
Ehtisham Ali
 
When & Why\'s of Denormalization
When & Why\'s of DenormalizationWhen & Why\'s of Denormalization
When & Why\'s of DenormalizationAliya Saldanha
 
Normalization in relational database management systems
Normalization in relational database management systemsNormalization in relational database management systems
Normalization in relational database management systems
Preethi T G
 
Normalization
NormalizationNormalization
Normalization
thuvarakan28
 
Database Normalization.docx
Database Normalization.docxDatabase Normalization.docx
Database Normalization.docx
SHARMISTHAlearning
 
Kumar lav
Kumar lavKumar lav
Kumar lav
kumar Lav
 
normaliztion
normaliztionnormaliztion
normaliztion
Ramadhani S. Zuberi
 
Chapter Four Logical Database Design (Normalization).pptx
Chapter Four Logical Database Design (Normalization).pptxChapter Four Logical Database Design (Normalization).pptx
Chapter Four Logical Database Design (Normalization).pptx
haymanot taddesse
 
Normalisation - 2nd normal form
Normalisation - 2nd normal formNormalisation - 2nd normal form
Normalisation - 2nd normal formcollege
 
Week 6 Normalization
Week 6 NormalizationWeek 6 Normalization
Week 6 Normalization
oudesign
 
Dwh lecture 07-denormalization
Dwh   lecture 07-denormalizationDwh   lecture 07-denormalization
Dwh lecture 07-denormalization
Sulman Ahmed
 
Dwh lecture-07-denormalization
Dwh lecture-07-denormalizationDwh lecture-07-denormalization
Dwh lecture-07-denormalization
Sulman Ahmed
 
De normalozation
De normalozationDe normalozation
De normalozation
Khuram Shahzad
 
Database normalisation by D.Lukachuk
Database normalisation by D.LukachukDatabase normalisation by D.Lukachuk
Database normalisation by D.Lukachuk
Dmytro Lukachuk
 
Persentation of SAD 2
Persentation of SAD 2Persentation of SAD 2
Persentation of SAD 2
Khaled Salmeen BAzqameh
 
DBMS 3.pdf
DBMS 3.pdfDBMS 3.pdf
DBMS 3.pdf
NithishReddy90
 
Normalization,ddl,dml,dcl
Normalization,ddl,dml,dclNormalization,ddl,dml,dcl

Similar to 2 normalization (20)

Entity relationship diagram - Concept on normalization
Entity relationship diagram - Concept on normalizationEntity relationship diagram - Concept on normalization
Entity relationship diagram - Concept on normalization
 
Normalization
NormalizationNormalization
Normalization
 
Normalization ppt for RDBMS PPT FOR BCA and for computer science student..pptx
Normalization ppt for RDBMS PPT FOR BCA and for computer science student..pptxNormalization ppt for RDBMS PPT FOR BCA and for computer science student..pptx
Normalization ppt for RDBMS PPT FOR BCA and for computer science student..pptx
 
Sql server ___________session3-normailzation
Sql server  ___________session3-normailzationSql server  ___________session3-normailzation
Sql server ___________session3-normailzation
 
When & Why\'s of Denormalization
When & Why\'s of DenormalizationWhen & Why\'s of Denormalization
When & Why\'s of Denormalization
 
Normalization in relational database management systems
Normalization in relational database management systemsNormalization in relational database management systems
Normalization in relational database management systems
 
Normalization
NormalizationNormalization
Normalization
 
Database Normalization.docx
Database Normalization.docxDatabase Normalization.docx
Database Normalization.docx
 
Kumar lav
Kumar lavKumar lav
Kumar lav
 
normaliztion
normaliztionnormaliztion
normaliztion
 
Chapter Four Logical Database Design (Normalization).pptx
Chapter Four Logical Database Design (Normalization).pptxChapter Four Logical Database Design (Normalization).pptx
Chapter Four Logical Database Design (Normalization).pptx
 
Normalisation - 2nd normal form
Normalisation - 2nd normal formNormalisation - 2nd normal form
Normalisation - 2nd normal form
 
Week 6 Normalization
Week 6 NormalizationWeek 6 Normalization
Week 6 Normalization
 
Dwh lecture 07-denormalization
Dwh   lecture 07-denormalizationDwh   lecture 07-denormalization
Dwh lecture 07-denormalization
 
Dwh lecture-07-denormalization
Dwh lecture-07-denormalizationDwh lecture-07-denormalization
Dwh lecture-07-denormalization
 
De normalozation
De normalozationDe normalozation
De normalozation
 
Database normalisation by D.Lukachuk
Database normalisation by D.LukachukDatabase normalisation by D.Lukachuk
Database normalisation by D.Lukachuk
 
Persentation of SAD 2
Persentation of SAD 2Persentation of SAD 2
Persentation of SAD 2
 
DBMS 3.pdf
DBMS 3.pdfDBMS 3.pdf
DBMS 3.pdf
 
Normalization,ddl,dml,dcl
Normalization,ddl,dml,dclNormalization,ddl,dml,dcl
Normalization,ddl,dml,dcl
 

More from Mr Patrick NIYISHAKA (20)

Summary
SummarySummary
Summary
 
3 summary
3 summary3 summary
3 summary
 
2 ddb architecture
2 ddb architecture2 ddb architecture
2 ddb architecture
 
1 ddb
1 ddb1 ddb
1 ddb
 
2 countermeasures
2 countermeasures2 countermeasures
2 countermeasures
 
2 countermeasures
2 countermeasures2 countermeasures
2 countermeasures
 
3 summary
3 summary3 summary
3 summary
 
1 db security
1 db security1 db security
1 db security
 
4 summary
4 summary4 summary
4 summary
 
3 summary
3 summary3 summary
3 summary
 
2 con control
2 con control2 con control
2 con control
 
1 con exe
1 con exe1 con exe
1 con exe
 
1 basic concepts
1 basic concepts1 basic concepts
1 basic concepts
 
2 recovery
2 recovery2 recovery
2 recovery
 
3 transaction
3 transaction3 transaction
3 transaction
 
3 summary
3 summary3 summary
3 summary
 
1 query processing
1 query processing1 query processing
1 query processing
 
1 query processing
1 query processing1 query processing
1 query processing
 
2 optimization
2 optimization2 optimization
2 optimization
 
2 collision
2 collision2 collision
2 collision
 

Recently uploaded

DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Ramesh Iyer
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
BookNet Canada
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
Product School
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Inflectra
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
OnBoard
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
Prayukth K V
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
Product School
 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
Elena Simperl
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
Alison B. Lowndes
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
DianaGray10
 
Generating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using SmithyGenerating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using Smithy
g2nightmarescribd
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
Thijs Feryn
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
ThousandEyes
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
UiPathCommunity
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Product School
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
ControlCase
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Albert Hoitingh
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 

Recently uploaded (20)

DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
 
Generating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using SmithyGenerating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using Smithy
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 

2 normalization

  • 1. Normalization 1. Definition ▪ The theory of relational databases includes some wisdom about what is and what is not good database design. These notions are expressed in terms of restrictions, each of which excludes certain undesirable properties from database designs. These sets of restrictions are called normal forms. And normalization is the name given to the process of creating a database design that does not violate them. ▪ A logical design method: -- which minimizes data redundancy and reduces design flaws. • Consists of applying various “normal” forms to the database design. • The normal forms break down large tables into smaller subsets.
  • 2. Normalization 2. Data Redundancy or Duplication ▪ Department name and manager are duplicated for all employees in the department. If redundancy exists then this can cause problems during normal database operations: • When data is inserted the database the data must be duplicated where ever redundant versions of that data exists. • When data is updated, all redundant data must be simultaneously updated to reflect that change. Consequences of redundancy • • • • Wasted space Potential performance cost Potential inconsistency Inability to represent data
  • 3. Normalization 3. Anomalies Insertion anomalies If a new employee is added to deptid 2, all the info about the department (name & manager) has to be re-input. A new department, say it, can be added only when there exists an employee for the new department. Deletion anomalies If the last employee from a department is deleted, then details of that department disappear from the database. Update anomalies If the sales manager of Jones is replaced by Smith, all the records for employees in sales department must be modified.
  • 4. Normalization 4. Benefits of Normalization • Less storage space • Quicker updates • Less data inconsistency • Clearer data relationships • Easier to add data • Flexible structure
  • 5. Normal Form 1. First Normal Form - 1nf • A relation is said to be in first normal form (1nf) if all attribute values are atomic: no repeating group, no composite attributes, and primary key is identified. Patient # Surgeon # Surgery date Patient name Patient addr Surgeon name Surgery Drug admin Side Effects 1111 145 01-jan-95 John white 15 new st. New york, ny Gallstones removal Penicillin Rash 1111 311 12-jun-95 John white 15 new st. New york, ny Beth little Michael diamon d Kidney stones removal None None 1234 243 05-apr-94 Mary jones 10 main st. Rye, ny Charles field Eye cataract removal Tetracycline Fever 1234 467 10-may-95 Mary jones 10 main st. Rye, ny Patricia gold Thrombosis removal None None 2345 189 08-jan-96 Charles brown Dogwood lane harrison, ny David rosen Open heart surgery Cephalosporin None 4876 145 05-nov-95 Hal kane 55 boston post road, chester, cn Beth little Cholecystectomy Demicillin None 5123 145 10-may-95 Paul kosher Blind brook mamaroneck, ny Beth little Gallstones removal None None 6845 243 05-apr-94 Ann hood Hilton road larchmont, ny Charles field Eye cornea replacement Tetracycline Fever 6845 243 15-dec-84 Ann hood Hilton road larchmont, ny Charles field Eye cataract removal None None • All attribute values are atomic because there are no repeating group and no composite attributes.
  • 6. Normal Form 2. Second Normal Form - 2nf Second normal form (2nf) further addresses the concept of removing duplicative data: • A relation r is in 2nf if (a) r is 1nf , and (b) all non-prime attributes are fully dependent on the candidate keys. Which is creating relationships between these new tables and their predecessors through the use of foreign keys. Partial dependency must be eliminated. Break the composite primary key into two parts, each part representing a separate table. • A prime attribute appears in a candidate key. • There is no partial dependency in 2nf.
  • 7. Normal Form 3. Third Normal Form - 3nf A relation is said to be in third normal form if there is no transitive functional dependency between nonkey attributes. • When one nonkey attribute can be determined with one or more nonkey attributes there is said to be a transitive functional dependency. The side effect column in the surgery table is determined by the drug administered. • Side effect is transitively functionally dependent on drug so surgery is not 3nf.
  • 8. Normal Form 4. Denormalization Though normalization is performed to reduce or eliminate insertion, deletion or update anomalies, a completely normalized database may not be the most efficient or effective implementation. “denormalization” is sometimes used to improve efficiency. Usually driven by the need to improve query speed. Query speed is improved at the expense of more complex or problematic DML (data manipulation language) for updates, deletions and insertions.