Storage and Indexing questions

Q46

GATE CS 2026 CS-2Storage and IndexingMCQ2 marks−2/3 if wrong
An index in a DBMS is said to be dense if an index entry appears for every search-key value in the indexed file. Otherwise it is called a sparse index. Consider the following two statements.

S1: A hash index must be a dense index

S2: A B+B^+ tree index can be a sparse index

Which one of the following options is correct?
Show answer without attempting

Answer: A

Q21

GATE CS 2025 CS-1Storage and IndexingMSQ1 mark
Consider the following B+B^+ tree with 5 nodes, in which a node can store at most 3 key values. The value 23 is now inserted in the B+B^+ tree. Which of the following options(s) is/are CORRECT?
Question figure
More than one option can be correct.
Show answer without attempting

Answer: B, D

Q57

GATE CS 2025 CS-2Storage and IndexingNAT2 marks
In a B+B^+- tree where each node can hold at most four key values, a root to leaf path consists of the following nodes:

A = (49, 77, 83, -), B = (7, 19, 33, 44), C = (20∗,22∗,25∗,26∗20^*, 22^*, 25^*, 26^*)

The *-marked keys signify that these are data entries in a leaf.

Assume that a pointer between keys k1k_1 and k2k_2 points to a subtree containing keys in [k1,k2)[k_1, k_2), and that when a leaf is created, the smallest key in it is copied up into its parent.

A record with key value 23 is inserted into the B+B^+- tree.

The smallest key value in the parent of the leaf that contains 25∗25^* is __________ . (Answer in integer)
Show answer without attempting

Answer: 33

Q21

GATE CS 2024 CS-1Storage and IndexingMCQ1 mark−1/3 if wrong
In a B+ tree, the requirement of at least half-full (50%) node occupancy is relaxed for which one of the following cases?
Show answer without attempting

Answer: A

Q26

GATE CS 2024 CS-2Storage and IndexingMSQ1 mark
Which of the following file organizations is/are I/O efficient for the scan operation in DBMS?
More than one option can be correct.
Show answer without attempting

Answer: A, B

Q53

GATE CS 2024 CS-2Storage and IndexingNAT2 marks
Consider a disk with the following specifications: rotation speed of 6000 RPM, average seek time of 5 milliseconds, 500 sectors/track, 512-byte sectors.
A file has content stored in 3000 sectors located randomly on the disk. Assuming average rotational latency, the total time (in seconds, rounded off to 2 decimal places) to read the entire file from the disk is _________
Show answer without attempting

Answer: 29.50 to 30.50

Q62

GATE CS 2023 CSStorage and IndexingNAT2 marks
Consider a database of fixed-length records, stored as an ordered file. The database has 25,000 records, with each record being 100 bytes, of which the primary key occupies 15 bytes. The data file is block-aligned in that each data record is fully contained within a block. The database is indexed by a primary index file, which is also stored as a block-aligned ordered file. The figure below depicts this indexing scheme.

Suppose the block size of the file system is 1024 bytes, and a pointer to a block occupies 5 bytes. The system uses binary search on the index file to search for a record with a given key. You may assume that a binary search on an index file of bb blocks takes ⌈log⁡2b⌉\lceil \log_2 b \rceil block accesses in the worst case.

Given a key, the number of block accesses required to identify the block in the data file that may contain a record with the key, in the worst case, is ____________.
Question figure
Show answer without attempting

Answer: 6

Q21

GATE CS 2021 CS-2Storage and IndexingNAT1 mark
A data file consisting of 1,50,000 student-records is stored on a hard disk with block size of 4096 bytes. The data file is sorted on the primary key RollNo. The size of a record pointer for this disk is 7 bytes. Each student-record has a candidate key attribute called ANum of size 12 bytes. Suppose an index file with records consisting of two fields, ANum value and the record pointer to the corresponding student record, is built and stored on the same disk. Assume that the records of data file and index file are not split across disk blocks. The number of blocks in the index file is ____________.
Show answer without attempting

Answer: 698

Q54

GATE CS 2020 CSStorage and IndexingNAT2 marks
Consider a database implemented using B+ tree for file indexing and installed on a disk drive with block size of 4 KB. The size of search key is 12 bytes and the size of tree/disk pointer is 8 bytes. Assume that the database has one million records. Also assume that no node of the B+ tree and no records are present initially in main memory. Consider that each record fits into one disk block. The minimum number of disk accesses required to retrieve any record in the database is __________.
Show answer without attempting

Answer: 4

Q14

GATE CS 2019 CSStorage and IndexingMCQ1 mark−1/3 if wrong
Which one of the following statements is NOT correct about the B+ tree data structure used for creating an index of a relational database table?
Show answer without attempting

Answer: B

Q49

GATE CS 2017 CS-2Storage and IndexingNAT2 marks
In a B+ tree, if the search-key value is 8 bytes long, the block size is 512 bytes and the block pointer size is 2 bytes, then the maximum order of the B+ tree is ____________.
Show answer without attempting

Answer: 52.0

Q21

GATE CS 2016 CS-2Storage and IndexingMCQ1 mark−1/3 if wrong
B+ Trees are considered BALANCED because
Show answer without attempting

Answer: A

Q39

GATE CS 2015 CS-3Storage and IndexingNAT2 marks
Consider a B+ tree in which the search key is 12 bytes long, block size is 1024 bytes, record pointer is 10 bytes long and block pointer is 8 bytes long. The maximum number of keys that can be accommodated in each non-leaf node of the tree is ____________.
Show answer without attempting

Answer: 50

Q32

GATE CS 2015 CS-1Storage and IndexingMCQ1 mark−1/3 if wrong
A file is organized so that the ordering of data records is the same as or close to the ordering of data entries in some index. Then that index is called
Show answer without attempting

Answer: C

Q32

GATE CS 2015 CS-2Storage and IndexingNAT1 mark
With reference to the B+ tree index of order 1 shown below, the minimum number of nodes (including the Root node) that must be fetched in order to satisfy the following query: "Get all records with a search key greater than or equal to 7 and less than 15" is ____________.
Question figure
Show answer without attempting

Answer: 5

Q15

GATE CS 2013 CSStorage and IndexingMCQ1 mark−1/3 if wrong
An index is clustered, if
Show answer without attempting

Answer: C

0/160 correct0 marks

Related topics in Databases