Jinny Cho
09/01/2022, 4:08 PMHAVING
clause (here). However when I try it, I receive the following error message. The query I tried was the same as what was written in the doc. Is this something new that we need to upgrade?
Caused by: org.apache.calcite.sql.parser.SqlParseException: Encountered "HAVING" at line 11, column 1.
Was expecting one of:
<EOF>
"LIMIT" ...
"OFFSET" ...
...
Mayank
Jinny Cho
09/01/2022, 5:05 PMMayank
Jinny Cho
09/01/2022, 5:09 PMSELECT
SUM(my_count) as counts,
my_term
FROM my_table
WHERE
shop_id = 123 AND
listing_id = 12345 AND
serve_time BETWEEN 1661918400 AND 1662004800
GROUP BY my_term
ORDER BY SUM(my_count) DESC
HAVING SUM(my_count) >= 5
LIMIT 100000;
Jinny Cho
09/01/2022, 5:10 PMJinny Cho
09/01/2022, 5:10 PMany other non-default features you may have enabledI don't think so? What are some of the non-default features for example?
Xiaobing
09/01/2022, 5:41 PMHAVING
before ORDER BY
like below? It worked on my side (with latest master branch btw).
SELECT
AirlineID,
sum(DepDelay) as value
FROM airlineStats
GROUP BY AirlineID
HAVING sum(DepDelay) >= 0
ORDER BY value DESC
I got same error if putting Having after OrderBy. This seems like a regression.Jinny Cho
09/01/2022, 6:18 PMJinny Cho
09/01/2022, 6:18 PMMayank
Jinny Cho
09/01/2022, 6:32 PMRong R
09/01/2022, 7:09 PMRong R
09/01/2022, 7:09 PM