yujun777 commented on code in PR #54953:
URL: https://github.com/apache/doris/pull/54953#discussion_r2289756864
##########
fe/fe-core/src/main/java/org/apache/doris/nereids/util/JoinUtils.java:
##########
@@ -484,4 +487,42 @@ public static boolean
checkReorderPrecondition(LogicalJoin<?, ?> top, LogicalJoi
markSlots.retainAll(bottom.getOutputSet());
return markSlots.isEmpty();
}
+
+ /**
+ * Use the children nullable property of the join to adjust the slot used
by the join conjuncts.
+ * Such as 'a left join b left join c where b.condition > 1'
+ * if the join change to '(b left join c) right a where b.condition > 1',
+ * the nullable property of b.condition should be false
+ */
+ public static LogicalJoin<Plan, Plan>
adjustJoinConjunctsNullable(LogicalJoin<Plan, Plan> join) {
Review Comment:
the logical should be like AdjustNullable.visitLogicalJoin, but here forget
to update mark join conditions. maybe can reconstruct
AdjustNullable.visitLogicalJoin, and expose a public function
AdjustNullable.adjustJoinNullableWithReplaceSlots(join, replaceMap)
--
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]