[fix](runtimefilter)slot comparison bug #34791

This commit is contained in:
minghong
2024-05-14 11:03:49 +08:00
committed by yiguolei
parent 95b05928fd
commit fcf26c9224
2 changed files with 4 additions and 4 deletions

View File

@ -389,7 +389,7 @@ public class RuntimeFilterPushDownVisitor extends PlanVisitor<Boolean, PushDownC
List<NamedExpression> output = setOperation.getOutputs();
for (int j = 0; j < output.size(); j++) {
NamedExpression expr = output.get(j);
if (expr.getName().equals(probeSlot.getName())) {
if (expr.getExprId().equals(probeSlot.getExprId())) {
projIndex = j;
break;
}
@ -397,10 +397,10 @@ public class RuntimeFilterPushDownVisitor extends PlanVisitor<Boolean, PushDownC
if (projIndex == -1) {
return false;
}
// probeExpr only has one input slot
for (int i = 0; i < setOperation.children().size(); i++) {
Map<Expression, Expression> map = Maps.newHashMap();
// probeExpr only has one input slot
map.put(ctx.probeExpr.getInputSlots().iterator().next(),
map.put(probeSlot,
setOperation.getRegularChildrenOutputs().get(i).get(projIndex));
Expression newProbeExpr = ctx.probeExpr.accept(ExpressionVisitors.EXPRESSION_MAP_REPLACER, map);
PushDownContext childPushDownContext = ctx.withNewProbeExpression(newProbeExpr);

View File

@ -103,7 +103,7 @@ public class PhysicalCTEConsumer extends PhysicalRelation {
.stream().forEach(rf -> builder.append(" RF").append(rf.getId().asInt()));
}
return Utils.toSqlString("PhysicalCTEConsumer[" + id.asInt() + "]",
"stats", getStats(), "cteId", cteId, "RFs", builder);
"stats", getStats(), "cteId", cteId, "RFs", builder, "map", consumerToProducerSlotMap);
}
@Override