CS FundamentalsVery hardGATE CS · PSU (ISRO/BARC)
A relation has 100,000 tuples and a selection σ_{city='Pune'} with an estimated selectivity of 2%. Each block holds 50 tuples and the relation is clustered (sorted) on city. Using a clustering B+ tree index of height 3 (excluding the data level), about how many block accesses are needed?
- A. 5 (3 + 2 data blocks)
- B. 2,000 (full scan)
- C. 2,003 (3 + one per matching tuple)
- D. 43 (3 index + 40 data blocks)
Correct answer: D. 43 (3 index + 40 data blocks)
2% of 100,000 = 2,000 matching tuples, stored contiguously in 2,000/50 = 40 blocks. Traversing the index costs 3, so about 43. A non-clustering index could need one block per tuple.
More DBMS and SQL questions
- Classify the schedule W1(A), R2(A), R1(B), R1(A), C1, R2(B), W2(A), C2 (Ci = commit of Ti) by the strongest property it satisfies.
- R(A, B, C, D, E, F) has the set of functional dependencies Σ = {CE → B, A → F, BE → D, AF → B}. Which of the following FDs is NOT in Σ⁺…
- For the schedule W4(C), W1(A), R4(B), R2(A), R3(C), W3(A), R2(B), R1(B), how many serial schedules of T1–T4 are conflict-equivalent to it?
- Extendible hashing uses the LOWEST-order bits of a key's binary value, bucket capacity 2, and starts with global depth 0 and one empty…
- Which statement about shadow paging is correct?
- A bitmap index is built on an attribute with 4 distinct values over a table of 1,000,000 rows (uncompressed, one bit per row per value)…