Skip to content

Predicates on nested-leaf columns fail #2432

Open

Description

@vvarma

Apache Iceberg Rust version

0.6.0 (latest version)

Describe the bug

Nested-leaf predicates in the Arrow reader are rejected even when the predicate targets a primitive leaf inside a struct.
For example, a predicate like:

nested.value = 20

fails during row-filter construction because PredicateConverter::bound_reference resolves the predicate field ID to a Parquet leaf column, then rejects it when the Parquet column root is a group/struct.

To Reproduce

No response

Expected behavior

No response

Willingness to contribute

I can contribute a fix for this bug independently

Activity

  1. LuciferYang commented on Jul 27, 2026

    @LuciferYang
    Contributor

    I hit this and opened #2906 for it.

    The fix resolves a predicate's field to its Parquet column path (root to leaf) rather than a single leaf index, and walks that path through the projected RecordBatch, descending struct children by name to reach the primitive leaf, so person.age > 25 builds a row filter instead of erroring on the group root.

    Scope note: this covers top-level and struct-nested leaves. Fields inside a list or map get no accessor in Schema::build_accessors, so a predicate on one already fails at bind time and never reaches the row filter, no change needed there. Row-group and page-index pruning resolve nested leaves by field id and didn't error on this path, so I left them out; happy to look at them separately if it's worth tightening.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions