walterddr commented on code in PR #12248:
URL: https://github.com/apache/pinot/pull/12248#discussion_r1450894193
##########
pinot-query-planner/src/test/resources/queries/LiteralEvaluationPlans.json:
##########
@@ -160,6 +160,29 @@
"\n"
]
},
+ {
+ "description": "select two functions chaining",
+ "sql": "EXPLAIN PLAN FOR SELECT ToEpochDays(fromDateTime('1970-01-15',
'yyyy-MM-dd')) FROM a",
+ "output": [
+ "Execution Plan",
+ "\nLogicalProject(EXPR$0=[14:BIGINT])",
+ "\n LogicalTableScan(table=[[a]])",
+ "\n"
+ ]
+ },
+ {
+ "description": "filter with two functions chaining",
+ "sql": "EXPLAIN PLAN FOR SELECT count(*) FROM a WHERE col1 >
ToEpochDays(fromDateTime('1970-01-15', 'yyyy-MM-dd'))",
+ "output": [
+ "Execution Plan",
+ "\nLogicalAggregate(group=[{}], agg#0=[COUNT($0)])",
+ "\n PinotLogicalExchange(distribution=[hash])",
+ "\n LogicalAggregate(group=[{}], agg#0=[COUNT()])",
+ "\n LogicalFilter(condition=[>(CAST($0):BIGINT NOT NULL, 14)])",
Review Comment:
could you add another test case where CAST is not being involved (to
validate the other codepath)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]