deniskuzZ opened a new pull request, #7016: URL: https://github.com/apache/hive/pull/7016
### What changes were proposed in this pull request? - HiveStorageHandler.canPrunePartitionsByExpr (default true): whether getPartitionsByExpr can evaluate a filter. - Iceberg answers false for a filter without an Iceberg form (e.g. minute(ts) on a day(ts) table); PartitionPruner then gives the scan every partition with an unknown match, as for a scan without a predicate. ### Why are the changes needed? Such a filter got no partitions back: the scan still read every file but carried the statistics of zero partitions (1 row), so every estimate above it started from one row; a MERGE or DELETE got 2 delete writers. 1TRC MERGE with such a filter (40 x r5d.4xlarge): 2 -> 1,009 DV writers, MERGE 2,283 -> 1,432 s (-37 %). ### Does this PR introduce _any_ user-facing change? No (estimates only; scans whose filters convert are unchanged). ### How was this patch tested? - iceberg_unconvertible_partition_filter.q (TestIcebergCliDriver); with canPrunePartitionsByExpr always true it fails. - update_iceberg_copy_on_write_partitioned.q.out regenerated: estimates of 1 row -> 7. - Regression, TestIcebergCliDriver: show_partitions_test, iceberg_insert_into_partition_with_evolution, iceberg_truncate_partition_with_evolution, desc_ice_tbl_part_spec, query_iceberg_metadata_of_partitioned_table, iceberg_colstats_analyze_evolution, use_basic_stats_from_iceberg, iceberg_part_colstats, iceberg_stats, delete_iceberg_partitioned_parquet (11 with the regenerated one). - Once HIVE-30293 merges, its dropped-source minute(ts) case belongs in iceberg_unconvertible_partition_filter.q. 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- 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]
