Find the WHERE Mistake
Find the Mistake Beginner
Question
This query has an error. Find and fix it:
Code
SELECT * FROM users WHERE age > 18 ORDER BY name;
Hint
Actually, this query is correct! Look more carefully at the syntax.
Explanation
This query is actually correct! SELECT * FROM users WHERE age > 18 ORDER BY name; is valid SQL. The WHERE filters users over 18, and ORDER BY sorts by name. No mistake here — sometimes the answer is 'no error'.
Related Resources
Related Lessons
- WHERE Clause
Learn WHERE.
Look up unfamiliar terms
A beginner-friendly glossary explains jargon in plain English — variables, functions, DOM, Promise, and more.
Decode error messages
Plain-English explanations of common errors — what they mean, why they happen, and how to fix them.
Build real projects
Apply what you learned by building guided projects with starter code and solutions.