Question
Find the read cost only (no writing costs) of Class |x| Enroll using nested loops with: 1 - Class as the outside loop and buffer
Find the read cost only (no writing costs) of Class |x| Enroll using nested loops with:
1 - Class as the outside loop and buffer size of only two blocks
2 - Enroll as the outside loop and buffers size of two blocks
3 - Class as the outside loop and buffer size of 10 blocks
4 - Enroll as the outside loop and buffer size of 10 blocks
(Based on the information provided below)
Assume we have the following information about a University database:
All tables are stored in packed form in blocks of length 4096 bytes.
Student has 10,000 tuples, each 200 bytes long. It is hashed on stuId, the primary key, and has a secondary non-clustered index on lastName, with three levels. There are 8000 values for lastName, 2000 values for firstName, 25 values for major, and 150 values for credit.
Faculty has 800 tuples of length 100 bytes. It has an index on facId, the primary key, with two levels. There is a secondary non-clustered index on department, with one level. facName has 650 values, department has 25 values, and rank has 4 values.
Class has 2500 tuples with length of 100 bytes. It is hashed on classNumber, the primary key, and has no secondary indexes. facId has 700 values here, schedule has 35 values, and room has 350 values.
Enroll has 50,000 tuples with length of 100 bytes. It has a composite index on the primary key, {classNumber, stuId}, with four levels, and it has no other index. The attribute grade has 10 values.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started