Your cart is currently empty!
1 Indexing (10 pts) [7] Suppose we want to build an index on a relation R which has a total of x records, with each block capable of holding either y records or z key-pointer pairs. Assuming x is divisible by y, please answer the following questions (if your value evaluates to a…
1 Indexing (10 pts)
(a) [3] Suppose you construct a simple single level index, and that index is dense. How many index blocks are required to access all of the records of R?
(b) [4] Suppose the index built is sparse. If the index stores a pointer to the lowest search key in each block, and the index is a simple single level index, how many data blocks do we need? How many index blocks do we need?
2 B+ tree (30 points)
Consider a B+ tree of degree 2 shown below:
3 Extensible Hashing (30 pts)
Assume you have a extensible hash table with hash function h(k) = k mod 13, expressed as a binary string of size 4, and data block of size 2 (i.e., it can accommodate two tuples). You are asked to index the following key values in order: 25, 13, 23, 21.
4 Linear Hashing (30 pts)
Consider a linear hash table with r ≤ 1.76n with each data block capable of holding 2 records (that is, the average number of record per bucket should not exceed 88% of the total number of records per block):