Skip to content

fix(datafusion): preserve MERGE predicate grouping across clauses - #1263

Merged
JingsongLi merged 1 commit into
apache:mainfrom
slfan1989:paimon-rust-1262
Oct 31, 2026
Merged

JingsongLi merged 1 commit into
apache:mainfrom
slfan1989:paimon-rust-1262

Conversation

@slfan1989

@slfan1989 slfan1989 commented Oct 31, 2026 •

Copy link
Copy Markdown
Contributor

Purpose

Linked issue: closes #1262

Fix MERGE clauses containing OR incorrectly processing rows already handled by an earlier clause, causing duplicate inserts or UPDATE errors.

Brief change log

  • Parenthesize matched and unmatched clause predicates before combining them with earlier-clause exclusions using AND.
  • Add regression tests for UPDATE/DELETE clauses and INSERT clauses on ordinary and Data Evolution tables.

Tests

  • Confirmed both new regression tests fail before the fix.

API and Format

No.

Documentation

No.

@JingsongLi JingsongLi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

+1

@JingsongLi
JingsongLi merged commit e11dacc into apache:main Oct 31, 2026
15 checks passed
@slfan1989

Copy link
Copy Markdown
Contributor Author

+1

Thanks @JingsongLi for reviewing and merging!

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] MERGE clauses containing OR can process the same row more than once

2 participants