Details
-
New Feature
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
None
Description
We do not yet have support for the SQL HAVING clause. HAVING is used to filter post-aggregation, typically against an aggregated column. For example:
SELECT c1, MAX(c2) FROM t GROUP BY c1 HAVING MAX(c2) > 100
HAVING expressions need not reference aggregates in the SELECT, for example:
SELECT c1, MAX(c2) FROM t GROUP BY c1 HAVING MIN(c2) > 100
HAVING expressions need not filter on aggregated columns, for example:
SELECT c1, MAX(c2) FROM t GROUP BY c1 HAVING c1 > 100
Lastly, HAVING expressions need not be used in conjunction with a GROUP BY, for example:
SELECT MAX(c1) FROM t HAVING MAX(c1) > 100
Attachments
Issue Links
- links to