Learning objectives
What you will be able to explain
- What is a 'Search Key' in the context of database indexing?
- An index entry in its simplest form consists of which of the following?
- Generally, how does the size of an index file compare to the size of the original data file?
- Match index type to characteristic
- Sparse Indices: True or False
- Binary Search on Data File
Section 01
What is a 'Search Key' in the context of database indexing? to Generally, how does the size of an index file compare to the size of the original data file?
01
What is a 'Search Key' in the context of database indexing?
02
An index entry in its simplest form consists of which of the following?
Guided checkpoint
Select all that apply.
03
Generally, how does the size of an index file compare to the size of the original data file?
Section 02
Match index type to characteristic to Binary Search on Data File
01
Match index type to characteristic
02
Sparse Indices: True or False
Guided checkpoint
State whether each statement is True or False.
03
Binary Search on Data File
Guided checkpoint
A data file contains 1,000,000 records stored in 10,000 blocks. If the file is sorted and we binary search directly on blocks, how many block accesses are needed in the worst case?
Section 03
Sparse Index Performance to Why are multi-level indices used?
01
Sparse Index Performance
Guided checkpoint
Using the same file (10,000 blocks), we build a sparse index with one entry per block. The index fits into 100 blocks. How many block accesses are needed if we binary search index first?
02
What is the primary advantage of a dense index over a sparse index for a non-sorted search key?
03
Why are multi-level indices used?
Guided checkpoint
Select all that apply.
Section 04
Multi-level Index Calculation to Primary vs. Secondary
01
Multi-level Index Calculation
Guided checkpoint
A primary index has 10,000 blocks. We create a second-level sparse index on top. Each index block holds 100 entries. How many blocks does second-level index occupy?
02
A 'Primary Index' is defined as an index where...
03
Primary vs. Secondary
Section 05
Can a secondary index (on an unsorted file) be sparse? to What is the benefit of using a bucket (indirection) level in a secondary index?
01
Can a secondary index (on an unsorted file) be sparse?
02
If we build a secondary index on a non-unique attribute (e.g., State), how can duplicates be handled?
Guided checkpoint
Select all that apply.
03
What is the benefit of using a bucket (indirection) level in a secondary index?
Section 06
Clustered vs. Non-clustered: True or False to Index operations
01
Clustered vs. Non-clustered: True or False
Guided checkpoint
State whether each statement is True or False.
02
What does ISAM stand for?
03
Index operations
Section 07
In data manipulation, what is a tombstone? to Total Accesses (Multilevel)
01
In data manipulation, what is a tombstone?
02
When inserting into a sorted file and target block is full, which strategies can be used?
Guided checkpoint
Select all that apply.
03
Total Accesses (Multilevel)
Guided checkpoint
Given a 3-level index (Root -> Intermediate -> Leaf) and data file: root is in memory; intermediate and leaf levels are on disk; data file is on disk. How many disk I/Os are needed to retrieve one record?
Section 08
To search for value in a sparse index, you look for... to If an index is built on a candidate key but the file is NOT sorted by that attribute, is it primary or secondary?
01
To search for value in a sparse index, you look for...
02
What are the costs associated with having many indices on one table?
Guided checkpoint
Select all that apply.
03
If an index is built on a candidate key but the file is NOT sorted by that attribute, is it primary or secondary?
Section 09
Index Pointers: True or False to If search key is not a candidate key (duplicates allowed) and file is sorted, sparse index entry for value points to...
01
Index Pointers: True or False
02
Space Overhead
Guided checkpoint
A data file has 1,000,000 records. A dense index is created. Each index entry (key + pointer) is 16 bytes. Block size is 4,096 bytes. How many index blocks are required?
03
If search key is not a candidate key (duplicates allowed) and file is sorted, sparse index entry for value points to...
Section 10
In a dense index on a non-sorted file, how are range queries (e.g., ) handled efficiently? to A 'Clustering Index' is another name for...
01
In a dense index on a non-sorted file, how are range queries (e.g., ) handled efficiently?
02
Matching performance rank (1 = Best)
Guided checkpoint
Rank search performance for a large sorted file (1 = Best).
03
A 'Clustering Index' is another name for...
Knowledge check
Turn understanding into recall.
The quiz now follows the same concepts in scored form. You can return to this lesson from the quiz whenever a gap appears.