jinxing64 commented on a change in pull request #1647: [CALCITE-3588] Support 
more operators in Join condition when convert …
URL: https://github.com/apache/calcite/pull/1647#discussion_r356925076
 
 

 ##########
 File path: 
core/src/main/java/org/apache/calcite/rel/rel2sql/SqlImplementor.java
 ##########
 @@ -193,102 +193,12 @@ public Result setOpToSql(SqlSetOperator operator, 
RelNode rel) {
    * @param node            Join condition
    * @param leftContext     Left context
    * @param rightContext    Right context
-   * @param leftFieldCount  Number of fields on left result
    * @return SqlNode that represents the condition
    */
-  public static SqlNode convertConditionToSqlNode(RexNode node,
-      Context leftContext,
-      Context rightContext,
-      int leftFieldCount,
-      SqlDialect dialect) {
-    if (node.isAlwaysTrue()) {
-      return SqlLiteral.createBoolean(true, POS);
-    }
-    if (node.isAlwaysFalse()) {
-      return SqlLiteral.createBoolean(false, POS);
-    }
-    if (node instanceof RexInputRef) {
-      Context joinContext = leftContext.implementor().joinContext(leftContext, 
rightContext);
-      return joinContext.toSql(null, node);
-    }
-    if (!(node instanceof RexCall)) {
-      throw new AssertionError(node);
 
 Review comment:
   I cannot figure out a counter-example when converting filter condition.
   Correct me if I'm wrong.

----------------------------------------------------------------
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

Reply via email to