rdblue commented on code in PR #6981:
URL: https://github.com/apache/iceberg/pull/6981#discussion_r1155366799
##########
api/src/main/java/org/apache/iceberg/expressions/ExpressionUtil.java:
##########
@@ -156,6 +158,19 @@ public static boolean selectsPartitions(
caseSensitive);
}
+ public static boolean isPartitionCol(BoundGroupBy expr, Table table) {
+ return table.specs().values().stream().allMatch(spec ->
isPartitionCol(expr, spec));
Review Comment:
This check seems overly broad. The aggregate can be pushed down if the
partition column exists in all specs that have matching data files. The table
may start out unpartitioned and have partitions added later, and then have the
initial data rewritten. We want to test whether the specs that are actually
used meet the requirement and stop aggregation if there's a problem.
--
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]