95402d7a-b0da-4b8a-b70c-52ba4ac298fe-image.png
0c72dda8-4e51-4d51-8585-2fcf7882b710-image.png
2a4ac89f-cbe7-4262-beca-6e3876e68e0a-image.png 082f8ac1-7529-4db9-a900-09500328d6c1-image.png
92668a31-5bc9-4143-aad4-1dd9ca0073e1-image.png
Assignment No. 02
Semester: Spring 2019
CS614: Data Warehousing
Total Marks: 10 Due Date: 30-May-2019
Objective:
The objective of this assignment is to enhance the learning capabilities of the students about:
• De-Normalization
• Pre-Joining
• Storage Issues of Pre-joining
Instructions:
Please read the following instructions carefully before submitting assignment:
You need to use MS word document to prepare and submit the assignment on VU-LMS.
It should be clear that your assignment will not get any credit if:
♣ The assignment is submitted after due date.
♣ The assignment is not in the required format (.doc or docx)
♣ The submitted assignment does not open or file is corrupt.
♣ Assignment is copied(partial or full) from any source (websites, forums, students, etc)
Assignment
Question
HyperMart is an online shopping store currently acquiring a large number of customers. To manage some performance issues this online store requires to de-normalize its database for order and Order detail tables.
Normalized table structures are given below:
Table Information
• Assume 1:12 record count ratio between Order master and Order detail for online store’s database
• Assume 10 million orders (120 million records in order detail).
• Assume 10 byte Order_ID.
• Assume 30 byte header for master and 60 byte header for detail tables.
Task
You are required to perform the following tasks:
Best of Luck!
CS614 Assignment Solution
DENORMALIZED Table
In pre-joining all columns are moved from the master table into the detail table
Detail table
2) Calculate the total space used with normalization
SOL:
Total space with normalization
= (H.S of master table * records in master table) + (H.S of detail table * records in detail table)
= (30 * 10) + (60 * 120)
= 300 + 7200
= 7.5 GB
¥ Calculate the total space used after de-normalization
Total space after de-normalization
= (H.S of detail table + H.S of master table – common join path (orde_id)) * (records in detail table)
= (60 + 30 - 10) * 120
= 80 * 120
=9600
9.6 GB