The Not Boring Movies SQL problem asks you to select movies from a Cinema table that have an odd ID and a description that is not "boring." Sort results by rating in descending order. This is a foundational SQL filtering and sorting problem.
Microsoft, Meta, Amazon, Google, and Bloomberg ask this as a quick SQL screening question. It tests basic WHERE clause conditions (odd ID using modulo, string inequality), and ORDER BY with direction. The database interview pattern is directly applied in its most fundamental form.
SQL WHERE + ORDER BY. SELECT * FROM Cinema WHERE id % 2 = 1 AND description != 'boring' ORDER BY rating DESC. The odd ID check uses modulo: id % 2 = 1 (or id & 1 = 1 for bitwise). The description filter uses != 'boring' or <> 'boring'.
Cinema table:
| id | movie | description | rating |
|---|---|---|---|
| 1 | War | Great Action | 8.9 |
| 2 | Science | Fictional | 8.5 |
| 3 | irish | A Masterpiece | 7.2 |
| 4 | Ice song | Boring | 7.0 |
Result: id=1 (odd, not boring, rating=8.9), id=3 (odd, not boring, rating=7.2). Order by rating DESC: rows 1, 3.
id % 2 != 0 (correct alternative) but writing id % 2 = 0 by mistake (even, wrong).description NOT LIKE 'boring' — this works only if exact; safer to use != 'boring'.Not Boring Movies is a SQL fundamentals warm-up. Nail the odd/even check (id % 2 = 1), string inequality (!= 'boring'), and ORDER BY direction — these three basic clauses appear in dozens of SQL interview problems. Practice writing clean WHERE clauses with multiple conditions using AND, and always verify ORDER BY direction requirements. Being fast and accurate on easy SQL shows you're ready for the harder multi-table join questions.
| Title | Difficulty | Topics | LeetCode |
|---|---|---|---|
| Fix Names in a Table | Easy | Solve | |
| Primary Department for Each Employee | Easy | Solve | |
| Queries Quality and Percentage | Easy | Solve | |
| Combine Two Tables | Easy | Solve | |
| Customers Who Never Order | Easy | Solve |