0
0
DBMS Theoryknowledge~5 mins

Index selection guidelines in DBMS Theory - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What is the main purpose of creating an index in a database?
An index helps speed up data retrieval by allowing the database to find rows faster without scanning the entire table.
Click to reveal answer
beginner
When should you avoid creating an index on a database column?
Avoid indexing columns that have many duplicate values or are updated very frequently, as indexes can slow down write operations.
Click to reveal answer
beginner
Why is it recommended to create indexes on columns used in WHERE clauses?
Because indexes on columns used in WHERE clauses help the database quickly filter rows matching the condition, improving query speed.
Click to reveal answer
intermediate
What type of columns are best suited for indexing?
Columns with high selectivity, meaning they have many unique values, are best for indexing because they help narrow down search results effectively.
Click to reveal answer
intermediate
How does a composite index differ from a single-column index?
A composite index includes multiple columns and is useful when queries filter or sort by more than one column together.
Click to reveal answer
Which column is best to index for faster searches?
AA column that is rarely used in queries
BA column with mostly repeated values
CA column with many unique values
DA column that is frequently updated
What is a downside of adding too many indexes?
ASlower data retrieval
BSlower data insertion and updates
CMore disk space saved
DQueries become less readable
When is a composite index most useful?
AWhen queries filter on multiple columns together
BWhen only one column is used in queries
CWhen columns have many duplicate values
DWhen the table is very small
Which of these is NOT a good candidate for indexing?
APrimary key column
BColumn used in JOIN conditions
CForeign key column
DColumn with many NULL values and duplicates
How does an index improve query performance?
ABy reducing the number of rows the database must check
BBy increasing the size of the table
CBy compressing the data
DBy scanning the entire table faster
Explain the key factors to consider when selecting columns for indexing.
Think about how indexes help searches and how they affect updates.
You got /4 concepts.
    Describe the difference between single-column and composite indexes and when to use each.
    Consider how queries filter data using one or more columns.
    You got /4 concepts.