chunweilei commented on a change in pull request #1998:
URL: https://github.com/apache/calcite/pull/1998#discussion_r464216262
##########
File path:
core/src/main/java/org/apache/calcite/rel/rules/AggregateProjectMergeRule.java
##########
@@ -128,7 +131,7 @@ public static RelNode apply(RelOptRuleCall call, Aggregate
aggregate,
i < newAggregate.getRowType().getFieldCount(); i++) {
posList.add(i);
}
- relBuilder.project(relBuilder.fields(posList));
+ relBuilder.projectNamed(relBuilder.fields(posList), originalFieldNames,
true);
Review comment:
Would the added project be removed by `ProjectRemoveRule`?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]