deniskuzZ commented on code in PR #6990:
URL: https://github.com/apache/hive/pull/6990#discussion_r4738170112
##########
iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergStorageHandler.java:
##########
@@ -247,6 +248,11 @@ public class HiveIcebergStorageHandler extends
DefaultStorageHandler implements
private static final List<FieldSchema> DV_DISTRIBUTION =
schema(ImmutableList.of(FILE_PATH));
+ // Iceberg cannot evaluate these virtual columns, so a predicate that reads
one of them is not pushed down
+ private static final Set<String> NON_PUSHABLE_VIRTUAL_COLS = Stream.of(
Review Comment:
No virtual column is an Iceberg schema column, so rather than keep a list
here, could we treat every virtual column as non-pushable? Something like this
in `VirtualColumn`:
````
public static boolean readsVirtualColumn(ExprNodeDesc expr) {
List<String> cols = expr.getCols();
return cols != null &&
cols.stream().anyMatch(VIRTUAL_COLUMN_NAME_MAP::containsKey);
}
````
VIRTUAL_COLUMN_NAME_MAP covers every enum value. Then use it here and in
DeleteSemanticAnalyzer#filtersOnVirtualColumn, so both places follow the same
rule
--
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]