Database Indexing: Beginner's Guide to Performance Optimization
A quiz to introduce database indexing techniques for optimizing performance.
Questions in this quiz
15 questions on Database Indexing: Beginner's Guide to Performance Optimization. Work through them here, then start the quiz to answer them and see your score.
1.What is the primary purpose of a database index?
- ATo increase storage space
- BTo backup data
- CTo speed up data retrieval
- DTo encrypt data
2.Which type of index is typically used for unique constraints?
- AComposite index
- BClustered index
- CUnique index
- DNon-clustered index
3.In a relational database, what does a clustered index do?
- AStores data in the order of the index
- BStores data in a random order
- CEncrypts the data
- DIncreases the size of the database
4.Which of the following is a disadvantage of using indexes?
- AIncreased storage requirements
- BImproved query performance
- CReduced data redundancy
- DFaster data retrieval
5.What is a composite index?
- AAn index on multiple columns
- BAn index that encrypts data
- CAn index on a single column
- DAn index that compresses data
6.Which SQL command is used to create an index?
- AUPDATE INDEX
- BINSERT INDEX
- CCREATE INDEX
- DDELETE INDEX
7.How does a non-clustered index differ from a clustered index?
- AIt does not change the physical order of data
- BIt encrypts the data
- CIt compresses the data
- DIt changes the physical order of data
8.What is the effect of an index on a SELECT query?
- AIt deletes data
- BIt speeds up the query
- CIt has no effect
- DIt slows down the query
9.Which of the following is true about a primary key index?
- AIt can have duplicate values
- BIt is always non-clustered
- CIt is always composite
- DIt uniquely identifies each row
10.What happens to the performance of INSERT operations when an index is present?
- APerformance improves
- BData is encrypted
- CPerformance degrades
- DPerformance remains unchanged
11.Which type of index is automatically created with a primary key?
- AComposite index
- BClustered index
- CNon-clustered index
- DUnique index
12.What is a covering index?
- AAn index that includes all columns needed by a query
- BAn index that encrypts data
- CAn index that compresses data
- DAn index that covers all columns in a table
13.What is the main benefit of using a bitmap index?
- AIncreases security
- BEfficient for high-cardinality columns
- CReduces storage space
- DEfficient for low-cardinality columns
14.Why might you use an index on a foreign key column?
- ATo slow down joins
- BTo encrypt the foreign key
- CTo compress the foreign key
- DTo speed up joins
15.Which of the following is a potential downside of having too many indexes?
- AIncreased data redundancy
- BReduced storage requirements
- CSlower data modification operations
- DFaster query performance