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

Tutorial 8: Relational Model and Database Normalization

The document describes a tutorial on relational database design and normalization. It lists the learning outcomes as describing the aims of good relational design through normalization, explaining potential data anomalies, identifying functional dependencies, and normalizing relations. The tutorial addresses normalization and database design. Sample exercises are provided to identify keys and dependencies, determine normal forms, and normalize relations.

Uploaded by

zia ul haq
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
142 views

Tutorial 8: Relational Model and Database Normalization

The document describes a tutorial on relational database design and normalization. It lists the learning outcomes as describing the aims of good relational design through normalization, explaining potential data anomalies, identifying functional dependencies, and normalizing relations. The tutorial addresses normalization and database design. Sample exercises are provided to identify keys and dependencies, determine normal forms, and normalize relations.

Uploaded by

zia ul haq
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Tutorial 8

Relational Model and Database Normalization

LEARNING OUTCOMES FOR THIS TUTORIAL


After completing this workshop you should be able to:
• Describe the aims of good relational database design through normalisation
• Explain the potential modification anomalies (update, insert and delete) associated with
redundant information in tables
• Identify functional dependencies among attributes
• Give definitions of the following normal forms: 1NF, 2NF, 3NF
• Be able to identify which normal form a given relation is in from examining its functional
dependencies
• Normalise a given relation to a higher normal form

This workshop addresses the following learning outcomes of the unit:

ULO_06: Demonstrate practical knowledge of normalisation and database design

Exercises on Normalization

Given the relation and functional dependencies;

Example: STUDENT (StudentNo, Name, PrimaryMajor, School)

FDs: StudentNo → Name, PrimaryMajor, PrimaryMajor → School

1. Candidate key is StudentNo, as if we know StudentNo we can find all other attributes from it

2. The original relation is in 2NF. There are no partial FDs so it is in 2NF at least. It is not in 3NF as
there is a transitive FD StudentNo → PrimaryMajor → School

3. 3NF relations:

STUDENT (StudentNo, Name, PrimaryMajor)

MAJOR (PrimaryMajor, School)

1
Given the following relation and functional dependencies:

a) Identify the candidate key(s) and partial functional dependencies among attributes (If any)
b) Explain which NF the relation is in.
c) Convert the relation into a relation or set of relations in at least 3NF

Q1. ENROLS (StudentNo, Name, UnitCode, UnitName, Grade)

FDs: StudentNo → Name

UnitCode → UnitName

StudentNo, UnitCode → Grade

Q2. Each loan application is by one customer but each customer may make many applications

ApplicNo Customer Address Date Appr

X97 JoeBlog Perth 2/3

X99 Vicki Sydney 3/3

Y72 JoeBlog Perth 3/3

Converting the table to a relation

Q3: Given the following table:

Part No Description Vendor Address UnitCost

1234 Logic Chip Fast Chips Perth 10.00

Smart Chips Sydney 5.00

5678 Memory chip Fast Chips Perth 3.00

Quality Chips Sydney 2.00

Smart Chips Sydney 5.00

2
a) Convert this table to a single relation (called PART-SUPPLIER) in first normal form. Illustrate the
relation with the same sample data.

b) List the functional dependencies in PART-SUPPLIER and identify the candidate key(s).

c) Convert PART-SUPPLIER to a set of relations in at least third normal form.

You might also like