rubenada commented on a change in pull request #1157: [CALCITE-2969] Improve 
design of join-like relational expressions
URL: https://github.com/apache/calcite/pull/1157#discussion_r283676253
 
 

 ##########
 File path: core/src/main/java/org/apache/calcite/rel/core/Join.java
 ##########
 @@ -230,6 +237,15 @@ public boolean isSemiJoinDone() {
     return false;
   }
 
+  /**
+   * Returns whether this Join is a semijoin.
+   *
+   * @return true if this is semi but without correlate variables.
+   */
+  public boolean isSemiJoin() {
 
 Review comment:
   @danny0405 I know it does not happen right now, but in the (near) future, we 
will also have Join instances with type=ANTI, which also outputs one side; so 
if we really need to add a new method, I'd propose it to have a more generic 
name, e.g. moving the SemiJoinType#returnsJustFirstInput logic into here:
   ```
     public boolean returnsJustFirstInput() {
       switch (this) {
       case SEMI:
       case ANTI:
         return true;
       default:
         return false;
       }
     }
   ```

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