Interview practice question
A query got slow as data grew
Backend Engineering · Relational Databases · Beginner
A query that finds orders by status was fast in testing but now takes 5 seconds in production. What do you do?
What a strong answer covers
Your AI report card counts how many of these ideas you cover.
- Run EXPLAIN ANALYZE.
- Likely missing index → full scan.
- Add index on filter columns.
- Consider composite with sort column.
- Re-test and monitor.
Practise this topic
Start without signing up. Sign in free to get an AI report card on your answer.