← Quiz: Indexing: all 10 questions
Quiz: Indexing · Question 6 of 10
An index exists on (city, created). Can WHERE city = 'Pune' alone use it?
An index exists on (city, created). Can WHERE city = 'Pune' alone use it?
- A.Yes — city is the leftmost column of the index
- B.No — both columns must be in the WHERE clause
- C.Only if created is NULL
- D.Only for a clustered index
Answer & explanation
Correct answer: Yes — city is the leftmost column of the index
The leftmost prefix of a composite index can be used on its own.
Can you get the rest right without peeking?
Take the timed Quiz: Indexing quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →