EmmyMiao87 commented on a change in pull request #6380:
URL: https://github.com/apache/incubator-doris/pull/6380#discussion_r683222613
##########
File path:
fe/fe-core/src/main/java/org/apache/doris/planner/SingleNodePlanner.java
##########
@@ -1838,6 +1837,11 @@ public PlanNode createJoinNode(Analyzer analyzer,
PlanNode outer, PlanNode inner
*/
private PlanNode createJoinNode(Analyzer analyzer, PlanNode outer,
TableRef innerRef,
SelectStmt selectStmt) throws
UserException {
+ // Before creating a build node, ensure that all required slots are
materialized,
+ // even if slots that are not needed by Statement outside.
+ // Otherwise, when select stmt and on-clause does not contain the Slot
of the Union Node on the right side of Join,
+ // it will cause an error, see Doris-6380.
+ materializeTableResultForCrossJoinOrCountStar(innerRef, analyzer);
Review comment:
Changing the order is not a good way
--
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]