You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by mo...@apache.org on 2023/03/14 08:13:17 UTC
[doris] branch revert-17716-1.2-lts-bugfix created (now a488727362)
This is an automated email from the ASF dual-hosted git repository.
morningman pushed a change to branch revert-17716-1.2-lts-bugfix
in repository https://gitbox.apache.org/repos/asf/doris.git
at a488727362 Revert "[fix](fe)project should be done inside subquery (#17716)"
This branch includes the following new commits:
new a488727362 Revert "[fix](fe)project should be done inside subquery (#17716)"
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[doris] 01/01: Revert "[fix](fe)project should be done inside subquery (#17716)"
Posted by mo...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
morningman pushed a commit to branch revert-17716-1.2-lts-bugfix
in repository https://gitbox.apache.org/repos/asf/doris.git
commit a488727362dc773a5eb45e1560b15233b9dade85
Author: Mingyu Chen <mo...@gmail.com>
AuthorDate: Tue Mar 14 16:13:08 2023 +0800
Revert "[fix](fe)project should be done inside subquery (#17716)"
This reverts commit db32b251e6a9c3b8307484803af34a0868093e25.
---
.../apache/doris/planner/NestedLoopJoinNode.java | 4 +--
.../org/apache/doris/planner/OlapScanNode.java | 42 ----------------------
.../java/org/apache/doris/planner/SelectNode.java | 3 +-
.../query_p0/group_concat/test_group_concat.out | 1 +
4 files changed, 4 insertions(+), 46 deletions(-)
diff --git a/fe/fe-core/src/main/java/org/apache/doris/planner/NestedLoopJoinNode.java b/fe/fe-core/src/main/java/org/apache/doris/planner/NestedLoopJoinNode.java
index 421c534860..4f4f0dfded 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/planner/NestedLoopJoinNode.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/planner/NestedLoopJoinNode.java
@@ -70,8 +70,8 @@ public class NestedLoopJoinNode extends JoinNodeBase {
public NestedLoopJoinNode(PlanNodeId id, PlanNode outer, PlanNode inner, TableRef innerRef) {
super(id, "NESTED LOOP JOIN", StatisticalType.NESTED_LOOP_JOIN_NODE, outer, inner, innerRef);
- tupleIds.addAll(outer.getOutputTupleIds());
- tupleIds.addAll(inner.getOutputTupleIds());
+ tupleIds.addAll(outer.getTupleIds());
+ tupleIds.addAll(inner.getTupleIds());
}
public boolean canParallelize() {
diff --git a/fe/fe-core/src/main/java/org/apache/doris/planner/OlapScanNode.java b/fe/fe-core/src/main/java/org/apache/doris/planner/OlapScanNode.java
index 582aef8de5..14577c1967 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/planner/OlapScanNode.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/planner/OlapScanNode.java
@@ -22,7 +22,6 @@ import org.apache.doris.analysis.BaseTableRef;
import org.apache.doris.analysis.BinaryPredicate;
import org.apache.doris.analysis.CastExpr;
import org.apache.doris.analysis.Expr;
-import org.apache.doris.analysis.ExprSubstitutionMap;
import org.apache.doris.analysis.InPredicate;
import org.apache.doris.analysis.IntLiteral;
import org.apache.doris.analysis.PartitionNames;
@@ -1244,45 +1243,4 @@ public class OlapScanNode extends ScanNode {
public String getSelectedIndexName() {
return olapTable.getIndexNameById(selectedIndexId);
}
-
- public void setOutputSmap(ExprSubstitutionMap smap, Analyzer analyzer) {
- if (smap.getRhs().stream().anyMatch(expr -> !(expr instanceof SlotRef))) {
- if (outputTupleDesc == null) {
- outputTupleDesc = analyzer.getDescTbl().createTupleDescriptor("OlapScanNode");
- outputTupleDesc.setTable(this.olapTable);
- }
- if (projectList == null) {
- projectList = Lists.newArrayList();
- }
- List<Expr> newRhs = Lists.newArrayList();
- List<Expr> newLhs = Lists.newArrayList();
- for (Expr expr : smap.getRhs()) {
- if (expr instanceof SlotRef && !((SlotRef) expr).getDesc().isMaterialized()) {
- continue;
- }
- if (outputSmap.mappingForRhsExpr(expr) != null) {
- newLhs.add(outputSmap.mappingForRhsExpr(expr));
- newRhs.add(expr);
- } else {
- SlotDescriptor slotDesc = analyzer.addSlotDescriptor(outputTupleDesc);
- slotDesc.initFromExpr(expr);
- slotDesc.setIsMaterialized(true);
- slotDesc.materializeSrcExpr();
- projectList.add(expr);
- newLhs.add(smap.mappingForRhsExpr(expr));
- newRhs.add(new SlotRef(slotDesc));
- }
- }
- outputSmap = new ExprSubstitutionMap(newLhs, newRhs);
- } else {
- outputSmap = smap;
- }
- }
-
- public List<TupleId> getOutputTupleIds() {
- if (outputTupleDesc != null) {
- return Lists.newArrayList(outputTupleDesc.getId());
- }
- return tupleIds;
- }
}
diff --git a/fe/fe-core/src/main/java/org/apache/doris/planner/SelectNode.java b/fe/fe-core/src/main/java/org/apache/doris/planner/SelectNode.java
index 6d78b5cb48..2baa6e6f13 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/planner/SelectNode.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/planner/SelectNode.java
@@ -32,7 +32,6 @@ import org.apache.doris.thrift.TPlanNodeType;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
-import java.util.ArrayList;
import java.util.List;
/**
@@ -42,7 +41,7 @@ public class SelectNode extends PlanNode {
private static final Logger LOG = LogManager.getLogger(SelectNode.class);
protected SelectNode(PlanNodeId id, PlanNode child, List<Expr> conjuncts) {
- super(id, new ArrayList<>(child.getOutputTupleIds()), "SELECT", StatisticalType.SELECT_NODE);
+ super(id, child.getTupleIds(), "SELECT", StatisticalType.SELECT_NODE);
addChild(child);
this.tblRefIds = child.tblRefIds;
this.nullableTupleIds = child.nullableTupleIds;
diff --git a/regression-test/data/query_p0/group_concat/test_group_concat.out b/regression-test/data/query_p0/group_concat/test_group_concat.out
index e61bd4fd4f..8caca13a7e 100644
--- a/regression-test/data/query_p0/group_concat/test_group_concat.out
+++ b/regression-test/data/query_p0/group_concat/test_group_concat.out
@@ -25,3 +25,4 @@ false
25699 1989
2147483647 255:1991:32767:32767
+
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org