deniskuzZ commented on code in PR #6512:
URL: https://github.com/apache/hive/pull/6512#discussion_r3558004041
##########
ql/src/java/org/apache/hadoop/hive/ql/optimizer/physical/Vectorizer.java:
##########
@@ -5190,6 +5244,11 @@ private static VectorPTFInfo
createVectorPTFInfo(Operator<? extends OperatorDesc
int[] keyInputColumnMap =
ArrayUtils.toPrimitive(keyInputColumns.toArray(new Integer[0]));
int[] nonKeyInputColumnMap =
ArrayUtils.toPrimitive(nonKeyInputColumns.toArray(new Integer[0]));
+ if (isPartitionOrderBy && partitionKeyCount > 1) {
+ reorderPartitionColumnsToMatchOutputOrder(outputSignature,
evaluatorCount, outputColumnProjectionMap,
Review Comment:
TBH, i am not sure it's a right place for the fix. I think the
PARTITION-BY-key restoration bug should be fixed in
VectorPTFOperator/VectorPTFGroupBatches — map partitionKey[i] to
keyWithoutOrderColumnMap positions by column number at the point of use —
rather than reordering VectorPTFInfo in the Vectorize
##########
ql/src/java/org/apache/hadoop/hive/ql/optimizer/physical/Vectorizer.java:
##########
@@ -5190,6 +5244,11 @@ private static VectorPTFInfo
createVectorPTFInfo(Operator<? extends OperatorDesc
int[] keyInputColumnMap =
ArrayUtils.toPrimitive(keyInputColumns.toArray(new Integer[0]));
int[] nonKeyInputColumnMap =
ArrayUtils.toPrimitive(nonKeyInputColumns.toArray(new Integer[0]));
+ if (isPartitionOrderBy && partitionKeyCount > 1) {
+ reorderPartitionColumnsToMatchOutputOrder(outputSignature,
evaluatorCount, outputColumnProjectionMap,
Review Comment:
TBH, i am not sure it's a right place for the fix.
I think the PARTITION-BY-key restoration bug should be fixed in
VectorPTFOperator/VectorPTFGroupBatches — map partitionKey[i] to
keyWithoutOrderColumnMap positions by column number at the point of use —
rather than reordering VectorPTFInfo in the Vectorizer
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]