Question: Consider a relational DBMS that has two relations: Emp ( employees ) and Dept ( departments ) . Emp ( id , name, age, salary,
Consider a relational DBMS that has two relations: Emp employees and DeptdepartmentsEmpid name, age, salary, dnameDeptdname location The Emp table has tuples, and each tuple has a fixed length of bytes. Theprimary key attribute id has a length of bytes. The Dept table has tuples, and each tuple has bytes. The primary keyattribute "dname" has a length of bytes.For simplicity, we assume each employee belongs to one and only one department, andeach department has employees. Each block has K bytes, in which bytesare reserved for the block header. No records span two or more blocks. Consider thefollowing disk organization strategy: Sequential: All the Emp records are placed sequentially based on their id's.Similarly, all Dept records are stored sequentially based on their names.Suppose we want to build a primary index INDEX on Emp.id and a secondary indexINDEX on Dept.location. Treat duplicates in the secondary index in a straightforwardway; that is each tuple should have an index entry. Assume: Each block pointer is bytes. Each record pointer is bytes. Index entries do not span blocks.For each index type dense and sparse compute the minimum number of blocks neededfor INDEX and INDEX respectively. Notice that some type of index may not makesense. That is compute the number of blocks for the following combinations: INDEX Dense; INDEX Sparse; INDEX Dense; INDEX Sparse.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
