kasakrisz commented on a change in pull request #1184:
URL: https://github.com/apache/hive/pull/1184#discussion_r460188483
##########
File path:
ql/src/java/org/apache/hadoop/hive/ql/optimizer/calcite/rules/HiveCardinalityPreservingJoinOptimization.java
##########
@@ -161,127 +174,118 @@ public RelNode trim(RelBuilder relBuilder, RelNode
root) {
return root;
}
- // 4. Collect fields for new Project on the top of Join backs
+ // 3. Join back tables to the top of original plan
Mapping newInputMapping = trimResult.right;
- RexNode[] newProjects = new RexNode[rootFieldList.size()];
- String[] newColumnNames = new String[rootFieldList.size()];
- projectsFromOriginalPlan(rexBuilder,
newInput.getRowType().getFieldCount(), newInput, newInputMapping,
- newProjects, newColumnNames);
+ Map<RexTableInputRef, Integer> tableInputRefMapping = new HashMap<>();
- // 5. Join back tables to the top of original plan
for (TableToJoinBack tableToJoinBack : tableToJoinBackList) {
- LOG.debug("Joining back table " +
tableToJoinBack.projectedFields.relOptHiveTable.getName());
+ LOG.debug("Joining back table " +
tableToJoinBack.joinedBackFields.relOptHiveTable.getName());
Review comment:
fixed
----------------------------------------------------------------
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]