Académique Documents
Professionnel Documents
Culture Documents
Reg Name Course Grade We can NOT
101 Fatima EE101 B reconstruct the
101 Fatima CS273 A
102 Fatima EE101 B
original relation
102 Fatima CS273 A from the
decomposition!
Normalization Theory
ID Name ID Course
100 Umar 100 CS101
100 SE103
100 CS201
Functional Dependencies
ID Name
Value of a certain set of attributes
determines uniquely the value for 100 Umar
another set of attributes. 101 Ali
102 Umar
Let R be a relation schema and and are two
sets of attributes in R, that is R and R
The functional dependency holds on R if
and only if
For any legal relation r (R), whenever any two tuples
t1 and t2 of r agree on the attributes , they also
agree on the attributes .
!t1[] = t2 [] t1[ ] = t2 [ ]
FD Example
R = (A, B, C, G, H, I)
F = { A B
A C
CG H
CG I
BH}
Some members of F+
A H transitivity from A B and B H
AG I augmenting A C with G, AG CG
and transitivity with CG I
More on FDs
Order Order Customer Customer Customer Product Product Product Unit Ordered
ID Date ID Name Address ID Name Finish Price Quantity
106 10.02.2016 2 Value Furniture F10 7 Dining Table Ash 800 2
Markaz
106 10.02.2016 2 Value Furniture F10 5 Bed Oak 900 2
Markaz
106 10.02.2016 2 Value Furniture F10 4 Writers Maple 600 1
Markaz Desk
107 15.02.2016 6 Furniture Golra 11 4-Dr Dresser Oak 500 3
Gallery
107 15.02.2016 6 Furniture Golra 4 Writers Maple 600 4
Gallery Desk
108 15.02.2016 2 Value Furniture F10 6 Bed Maple 900 1
Markaz
109 16.02.2016 7 Office Valley Golra 8 Office Desk Ash 500 4
Checkpoint 2 - Solution
Functional Dependencies
multiple
Head-> Campus overlapping
Department, Campus -> Head candidate keys
Checkpoint
CNIC Name License Reg Num Ticket Fine Date Violation Violation Fine
Num Num Code Summary
3039399 Ali L4441 LHR-123 8080 13/12/2008 2 Speed 500
Normalization Steps
Remove anomalies
of multiple BCNF
candidate keys
Remove transitive
dependencies 3NF
Remove partial
dependencies 2NF
Remove multi-
valued attributes 1NF