danny0405 commented on a change in pull request #1492: [CALCITE-3390] Add ITEM
expression to SqlKind and include it in the p…
URL: https://github.com/apache/calcite/pull/1492#discussion_r335270203
##########
File path:
core/src/test/java/org/apache/calcite/test/RexProgramBuilderBase.java
##########
@@ -316,6 +317,14 @@ protected RexNode add(RexNode n1, RexNode n2) {
return rexBuilder.makeCall(SqlStdOperatorTable.PLUS, n1, n2);
}
+ protected RexNode item(RexInputRef inputRef, int index) {
+ RexNode rexNode = rexBuilder.makeCall(
+ SqlStdOperatorTable.ITEM,
+ inputRef,
Review comment:
The `ITEM` operator can take both INTEGER and VARCHAR as 1th arguments, if
the left record is a `MAP` type, the 1th argument can be type of the `MAP` key
type, so only a index here is not a complete implementation.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services