0% found this document useful (0 votes)
112 views

Normalization Example Document

Database normalization example.
Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
112 views

Normalization Example Document

Database normalization example.
Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 7

Table in 1 Normal Form (Elimination of Repeating Groups)

StdSSN STDClass OfferNO OffYear Enrgrade courseNo crsdesc


2 Normal Form - Identify FDs by creating FDD & FD lists
FD Lists:
StdSSN StdCit! StdClass
"fferNo "ffTerm! "ff#ear! CourseNo! CrsDes$
CourseNo CrsDes$
StdSSN! "fferNo EnrGrade
StdSSN StdCity StdClass OfferNo OffTerm OffYear EnrGrade CourseNo CrsDesc
% NF & 'iolation rules: E'er non(e $olumn depends on all $andidate (es!
not a subset of an $andidate (e
FD Lists:
StdSSN StdCit! StdClass
"fferNo "ffTerm! "ff#ear! CourseNo! CrsDes$
CourseNo CrsDes$
StdSSN! "fferNo EnrGrade
Tables in % NF
StdSSN StdCit! StdClass
"fferNo "ffTerm! "ff#ear! CourseNo! CrsDes$
StdSSN! "fferNo EnrGrade
)NF rules: non(e $olumn identifies anot*er non(e $olumn
CourseNo +++ CrsDes$ +++ 'iolation
Non (e +++ Non (e $olumn
"fferNo "ffTerm! "ff#ear! CourseNo! CrsDes$
"fferNo "ffTerm! "ff#ear! CourseNo (F,)
CourseNo ++ CrsDes$
"fferNo "ffTerm! "ff#ear! CourseNo (f()
CourseNo CrsDes$
2.1 (OfferNo, OffTerm, OffYear, courseNo)
%-% (CourseNo! CrsDes$)
Final list of tables:
Table 1 (StdSSN StdCit! StdClass)
Table % ("fferNo! "ffTerm! "ff#ear! $ourseNo)
Table ) (CourseNo! CrsDes$)
Table . StdSSN! "fferNo EnrGrade
/alidation of normali0ed tables: ++ inserts! deletes! updates
Table 1
StdSSN StdCit StdClass
111 SSpring D2ST341
111 SS5ring D2ST33% + 6NSERT 7N"87L#
11% C57R, D2ST341
Delete from student 9*ere stdssn :111 and std$lass :;D2ST341;<
N" DELETE 7N"87L#
=5D7TE student set std$lass : >D2ST33?; 9*ere stdssn :111 and
std$lass:;D2ST341;<
111 SSpring D2ST33?
N" =5D7TE 7N"87L#
Steps to normali0ation:
1- C*e$( for anomalies +++ if es t*en normali0ation is needed-
%- C*e$( if t*e table *as repeating groups & #es +++ 'iolates 1 NF
)- Fi@ for 1NF 'iolation: eliminating repeating groups & meets 1 NF
.- Create FD diagram
4- Create FD lists
3- C*e$( for % NF 'iolation
A- Group t*e tables meeting % NF
?- C*e$( for ) NF 'iolation
B- Group t*e table to meet ) NF
11- Test t*e final tables to 'erif t*at t*ere are no anomalies
11- Final tables to satisf ) NF

You might also like