Zoltan Borok-Nagy has uploaded this change for review. ( 
http://gerrit.cloudera.org:8080/25194


Change subject: IMPALA-15637: Bind pushed down Iceberg predicates to the right 
columns
......................................................................

IMPALA-15637: Bind pushed down Iceberg predicates to the right columns

IcebergPredicateConverter refers to columns by name, and Iceberg binds
the names to the current schema of the table, or to the schema of the
snapshot for time travel to an older snapshot. The name doesn't always
refer to the same field as the Impala column:
 - The hidden columns of V3 tables, e.g. _file_row_id, are not in the
   Iceberg schema, so planning failed.
 - Time travel to the current snapshot reads it with the schema it was
   created with, because schema changes don't create snapshots. Iceberg
   binds the predicates to the current schema though. After two columns
   swapped names, the predicates were bound to the other column and
   Iceberg skipped files with matching rows. After a column was renamed
   or dropped, planning failed.

The converter now uses the schema that Iceberg binds the predicates to,
and only converts predicates on columns whose name refers to the same
field id in that schema.

Testing:
 - Added EE tests for hidden columns and time travel after schema
   changes.

Change-Id: I52dc21a8cf99145cb3f9ef7d57864b75b8b95bc8
Assisted-by: Claude Opus 5.5 (Claude Code)
---
M fe/src/main/java/org/apache/impala/common/IcebergPredicateConverter.java
M fe/src/main/java/org/apache/impala/planner/IcebergScanPlanner.java
M testdata/workloads/functional-query/queries/QueryTest/iceberg-time-travel.test
M 
testdata/workloads/functional-query/queries/QueryTest/iceberg-v3-row-lineage.test
M tests/query_test/test_iceberg.py
5 files changed, 107 insertions(+), 3 deletions(-)



  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/94/25194/1
--
To view, visit http://gerrit.cloudera.org:8080/25194
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I52dc21a8cf99145cb3f9ef7d57864b75b8b95bc8
Gerrit-Change-Number: 25194
Gerrit-PatchSet: 1
Gerrit-Owner: Zoltan Borok-Nagy <[email protected]>
Gerrit-Reviewer: Peter Rozsa <[email protected]>

Reply via email to