CS614 Assignment 1
CS614 Assignment 1
Question No.1
Table 1: Staff Branch given below reflects a specific form of normalization.
Staff No. Name position Salary Branch No. Branch Address TelNo.
S17005 Rizwan Manager 300000 B001 7 — st. Al Anayat Co. G- 302-3332-2
Ahmed 11 Islamabad.
S15002 Arifa Javed Assistant 80000 B001 7th — st. Al Anayat Co. G- 302-3332-2
11 Islamabad.
S23361 Ahmed Ali Manager 300000 B002 City Center Plaza, 420-5847-5
Karachi
S40021 Salinan Ahmed Assistant 750000 B002 City Center Plaza, 420-5847-5
Karachi
S00129 Hafza Khan Supervisor 90000 B003 Naz Digital Plaza, 205-2584-3
Lahore.
S01352 Ameer Ali Manager 200000 B004 Yusif plaza Rawalpindi 305-4561-9
You are required to identify the normalization form(NF) of the given table and also transform the given table
into the 3rd normalization form (3NF) and provide the resultant tables.
Note: To convert in 3NF, first you need to convert it in 2NF, and resultant tables of 3NF are only required.
Solution:
Now, let's further normalize the tables into 3NF. Since there are no transitive dependencies, both tables are
already in 3NF.
Resultant Tables:
Table 1.1: Staff Details
Staff No | Name | Position | Salary
So, the tables after normalization are already in 3NF, and the decomposition has resulted in the Staff Details
and Branch Details tables.
Question No.2
Table1 (Master):
Header Size of the CUSTOMER table: = 60 Bytes
Number of records stored in CUSTOMER table: = 70000
Table2 (Detail):
Header size ORDER table: = 70 Bytes
Number of records stored in ORDER table: = 5000000
Suppose you have applied the pre-joining De-Normalization technique on the ‘CUSTOMER’ and ‘ORDER’
tables.
Calculate the size of the resultant table in Megabytes (MB), Gigabytes (GB), and Terabytes (TB). The
reference column in these two tables is 8 bytes.
Answer:
The header of resultant de-normalization = 60+70 =130 bytes
Subtract the reference column in these two tables bytes is = 130-8 =122 bytes
According to the records in de-normalized table the size of de-normalization is = 122*5000000
=61,000,000 bytes