Fredy Wijaya created IMPALA-7250:
------------------------------------
Summary: AnalysisException in select datediff() with group by
Key: IMPALA-7250
URL: https://issues.apache.org/jira/browse/IMPALA-7250
Project: IMPALA
Issue Type: Bug
Components: Frontend
Affects Versions: Impala 2.12.0, Impala 3.0
Reporter: Fredy Wijaya
{noformat}
[localhost:21000] default> select datediff(day,now()) from test_table where
day>=(now() - interval 5 days) group by datediff(day,now());
Query: select datediff(day,now()) from test_table where day>=(now() - interval
5 days) group by datediff(day,now())
Query submitted at: 2018-06-05 21:11:23 (Coordinator: http://impala-dev:25000)
ERROR: AnalysisException: select list expression not produced by aggregation
output (missing from GROUP BY clause?): datediff(day, TIMESTAMP '2018-06-05
21:11:23.320564000')
[localhost:21000] default> set ENABLE_EXPR_REWRITES=0;
ENABLE_EXPR_REWRITES set to 0
[localhost:21000] default> select datediff(day,now()) from test_table where
day>=(now() - interval 5 days) group by datediff(day,now());
Query: select datediff(day,now()) from test_table where day>=(now() - interval
5 days) group by datediff(day,now())
Query submitted at: 2018-06-05 21:11:31 (Coordinator: http://impala-dev:25000)
Query progress can be monitored at:
http://impala-dev:25000/query_plan?query_id=b64c8eabcedc58e5:da9edc8600000000
Fetched 0 row(s) in 0.21s
{noformat}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]