rubenada commented on a change in pull request #2002:
URL: https://github.com/apache/calcite/pull/2002#discussion_r435232116
##########
File path: core/src/main/java/org/apache/calcite/rel/rules/JoinCommuteRule.java
##########
@@ -145,6 +145,12 @@ public static RelNode swap(Join join, boolean
swapOuterJoins,
.build();
}
+ public boolean matches(RelOptRuleCall call) {
+ Join join = call.rel(0);
+ // SEMI and ANTI join cannot be swapped.
+ return join.getJoinType().projectsRight();
+ }
Review comment:
You're right. I will create a test case.
----------------------------------------------------------------
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]