SQL - GROUP BY and HAVING
Identify the error in this query:
SELECT category, COUNT(*) FROM products HAVING COUNT(*) > 10 GROUP BY category;
Identify the error in this query:
SELECT category, COUNT(*) FROM products HAVING COUNT(*) > 10 GROUP BY category;
GROUP BY first, then HAVING.HAVING before GROUP BY, causing syntax error.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions