All jobs / Database administrator / Performance

Database administrator interview question · 0–1 years

You index a status column that has three possible values and the query is no faster. Why?

The strongest answer

It is not selective — most rows match, so following the index would still touch nearly every row and a scan is cheaper; indexes pay when the lookup eliminates most of the table

Why it works

Right — selectivity, not the existence of an index, decides whether a seek beats a scan.

What a good answer covers

Answers that fall short

Who gets asked this

More Performance questions