[ 
https://issues.apache.org/jira/browse/IOTDB-1875?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17433806#comment-17433806
 ] 

Xiangdong Huang commented on IOTDB-1875:
----------------------------------------

Hi [~JonWang], I have add permission to allow you assign yourself to take over 
any issue on JIRA :D

> Cast exception on invalid nested aggregation function call
> ----------------------------------------------------------
>
>                 Key: IOTDB-1875
>                 URL: https://issues.apache.org/jira/browse/IOTDB-1875
>             Project: Apache IoTDB
>          Issue Type: Improvement
>            Reporter: Zhong Wang
>            Assignee: Zhong Wang
>            Priority: Major
>              Labels: pull-request-available
>
> For queries like SELECT first_value(abs(s1)) from root.sg.d1, the following 
> exception will be thrown:
> java.lang.ClassCastException: 
> org.apache.iotdb.db.query.expression.unary.FunctionExpression cannot be cast 
> to org.apache.iotdb.db.query.expression.unary.TimeSeriesOperand
>  at 
> org.apache.iotdb.db.qp.logical.crud.SelectComponent.getPaths(SelectComponent.java:100)
>  at 
> org.apache.iotdb.db.qp.logical.crud.QueryOperator.generateRawDataQueryPlan(QueryOperator.java:193)
>  at 
> org.apache.iotdb.db.qp.logical.crud.GroupByQueryOperator.generatePhysicalPlan(GroupByQueryOperator.java:36)
>  at 
> org.apache.iotdb.db.qp.strategy.PhysicalGenerator.transformToPhysicalPlan(PhysicalGenerator.java:39)
>  at org.apache.iotdb.db.qp.Planner.parseSQLToPhysicalPlan(Planner.java:62)
>  at 
> org.apache.iotdb.db.service.TSServiceImpl.executeStatement(TSServiceImpl.java:607)
>  
> According to the implementation, the argument of built-in aggregation 
> functions must be a time series, but this constraint is not checked.
>  
> I will fix this issue.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to