Problems / Having Filter / Editorial
customer_id
SUM(amount) > 500
WHERE operates on individual rows *before* grouping. HAVING operates on aggregated values *after* grouping. You cannot reference aggregates in a WHERE clause — use HAVING instead.
WHERE
HAVING
Solve Having Filter yourself →