Presentation is loading. Please wait.

Presentation is loading. Please wait.

Normalization Exercises

Similar presentations


Presentation on theme: "Normalization Exercises"— Presentation transcript:

1 Normalization Exercises

2 Normalization Example 1

3 1st Normal Form

4 2nd Normal Form Create 3 Tables Distribute the remaining Attributes
COMPID INSTDATE SOFTCOST EMPNUM EMPNAME LOCATION PACKID TAGNUM

5 2nd Normal Form INSTDATE, SOFTCOST
PACKID TAGNUM INSTDATE, SOFTCOST (none in this example), could be things like package name, version, etc. COMPID, EMPNUM, EMPNAME, LOCATION Because the Package table has only one field (PACKID), we really don’t need this table

6 3rd Normal Form PACKID TAGNUM X

7

8 Normalization Example 2
Don’t be tricked!!! The first column of the data is not always the primary key of the 1NF table.

9 1st Normal Form If 1NF has only one column as the primary key (no composite key) then 1NF and 2NF are the SAME!!!!!

10 2nd Normal Form

11 3rd Normal Form Knowing the nature of the information, we can see that one person can have two cars and probably LIC_PLATE_NO should be the primary key for the REGISTRATION table and the foreign key for the PARKING_TICKETS table and that another table with LIC_PLATE_NO and LIC_PLATE_ST as a primary key and SSN as a foreign key should exist

12 3rd Normal Form

13

14 Normalization Example 3

15 1st Normal Form

16 2nd Normal Form

17 3rd Normal Form


Download ppt "Normalization Exercises"

Similar presentations


Ads by Google