[fix](explode-map) fix explode_map with alias (#39972)
## Proposed changes backport: https://github.com/apache/doris/pull/39757 Issue Number: close #xxx <!--Describe your changes.-->
This commit is contained in:
@ -271,7 +271,8 @@ public class BindExpression implements AnalysisRuleFactory {
|
||||
for (int idx = 0; idx < fields.size(); ++idx) {
|
||||
expandAlias.add(new Alias(new StructElement(
|
||||
boundSlot, new StringLiteral(fields.get(idx).getName())),
|
||||
generate.getExpandColumnAlias().get(i).get(idx)));
|
||||
generate.getExpandColumnAlias().get(i).get(idx),
|
||||
slot.getQualifier()));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -60,6 +60,10 @@ public class Alias extends NamedExpression implements UnaryExpression {
|
||||
this(exprId, ImmutableList.of(child), name, ImmutableList.of(), false);
|
||||
}
|
||||
|
||||
public Alias(Expression child, String name, List<String> qualifier) {
|
||||
this(StatementScopeIdGenerator.newExprId(), ImmutableList.of(child), name, qualifier, false);
|
||||
}
|
||||
|
||||
public Alias(ExprId exprId, Expression child, String name, boolean nameFromChild) {
|
||||
this(exprId, ImmutableList.of(child), name, ImmutableList.of(), nameFromChild);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user