-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Closed
Labels
beginner-taskSmall task for new contributors to ramp upSmall task for new contributors to ramp upfeature
Description
SQL defines the extract expression that can be used to access components of temporal datatypes. Calcite already supports it, so when an expression includes an extract function it parses. But once Pinot tries to convert it to its own expression AST, it fails with:
ProcessingException(errorCode:150, message:PQLParsingError:
java.lang.ClassCastException: class org.apache.calcite.sql.SqlIntervalQualifier cannot be cast to class org.apache.calcite.sql.SqlBasicCall (org.apache.calcite.sql.SqlIntervalQualifier and org.apache.calcite.sql.SqlBasicCall are in unnamed module of loader 'app')
at org.apache.pinot.sql.parsers.CalciteSqlParser.toExpression(CalciteSqlParser.java:682)
at org.apache.pinot.sql.parsers.CalciteSqlParser.compileFunctionExpression(CalciteSqlParser.java:737)
at org.apache.pinot.sql.parsers.CalciteSqlParser.toExpression(CalciteSqlParser.java:682)
at org.apache.pinot.sql.parsers.CalciteSqlParser.toExpression(CalciteSqlParser.java:619))
Pinot already have functions like minute, year, etc so this seems to be a matter of syntax.
Metadata
Metadata
Assignees
Labels
beginner-taskSmall task for new contributors to ramp upSmall task for new contributors to ramp upfeature