Skip to content

[branch-52] fix: filter pushdown when merge filter (#20110)#20289

Merged
alamb merged 2 commits intoapache:branch-52from
haohuaijin:branch-52-fix-filter-pushdown
Feb 12, 2026
Merged

[branch-52] fix: filter pushdown when merge filter (#20110)#20289
alamb merged 2 commits intoapache:branch-52from
haohuaijin:branch-52-fix-filter-pushdown

Conversation

@haohuaijin
Copy link
Contributor

Which issue does this PR close?

Rationale for this change

see issue #20109

What changes are included in this PR?

  1. Remap parent filter expressions: When a FilterExec has a projection, remap unsupported parent filter expressions from output schema coordinates to input schema coordinates using reassign_expr_columns() before combining them with the current filter's predicates.

  2. Preserve projection: When creating the merged FilterExec, preserve the original projection instead of discarding it .

Are these changes tested?

yes, add some test case

Are there any user-facing changes?


Which issue does this PR close?

  • Closes #.

Rationale for this change

What changes are included in this PR?

Are these changes tested?

Are there any user-facing changes?

## Which issue does this PR close?

- Closes apache#20109

## Rationale for this change

see issue apache#20109

## What changes are included in this PR?

1. Remap parent filter expressions: When a FilterExec has a projection,
remap unsupported parent filter expressions from output schema
coordinates to input schema coordinates using `reassign_expr_columns()`
before combining them with the current filter's predicates.

2. Preserve projection: When creating the merged FilterExec, preserve
the original projection instead of discarding it .

## Are these changes tested?

yes, add some test case

## Are there any user-facing changes?

---------

Co-authored-by: Adrian Garcia Badaracco <[email protected]>
@github-actions github-actions bot added core Core DataFusion crate physical-plan Changes to the physical-plan crate labels Feb 11, 2026
@haohuaijin
Copy link
Contributor Author

cc @alamb @adriangb

@alamb
Copy link
Contributor

alamb commented Feb 11, 2026

This is a backport of the following PR, right?

@alamb alamb changed the title [branch-52]fix: filter pushdown when merge filter (#20110) [branch-52] fix: filter pushdown when merge filter (#20110) Feb 11, 2026
@haohuaijin
Copy link
Contributor Author

This is a backport of the following PR, right?

yes

Copy link
Contributor

@alamb alamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @haohuaijin

@alamb alamb merged commit 8aaa274 into apache:branch-52 Feb 12, 2026
55 of 56 checks passed
@haohuaijin haohuaijin deleted the branch-52-fix-filter-pushdown branch February 12, 2026 01:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core Core DataFusion crate physical-plan Changes to the physical-plan crate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants