Data in Practice HQ
SQL Interview Preparation
50 real-world SQL challenges designed to help Data Engineers, Analytics Engineers, BI Developers and Data Analysts practise, reason through and explain SQL confidently in interviews.


Challenge 1: Customer Orders
You have an orders table containing customer orders. Write a query to find the total number of orders for each customer, sorted by the number of orders.
Don’t just write the SQL.
Explain your thinking.
SQL interviews aren’t only about reaching the right answer. This workbook helps you practise how to approach the problem, explain your reasoning, recognise common pitfalls and respond to follow-up questions.


50 challenges. Built around the SQL you’ll actually use.
Practise across SQL fundamentals, analytical and window functions, real-world data problems, data engineering patterns, PostgreSQL and Athena/Trino — with worked solutions, key takeaways and interview-focused guidance.
Ready to practise for your next SQL interview?
Get all 50 real-world SQL challenges, worked solutions, interview guidance, 20 quick-fire questions and the final preparation checklist in one 51-page workbook.
