Skip to content

fix(schema): reject moves involving missing fields - #1178

Merged
wgtmac merged 4 commits into
apache:mainfrom
WZhuo:fix/schema-move-missing-fields
Dec 1, 2026
Merged

wgtmac merged 4 commits into
apache:mainfrom
WZhuo:fix/schema-move-missing-fields

Conversation

@WZhuo

@WZhuo WZhuo commented Nov 26, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Return a validation error when the column being moved or its reference column is missing from the schema being updated. This prevents a move combined with deletion of its reference column from silently dropping the moved column.
  • Add one regression test covering deletion of the moved column and deletion of the reference column for both MoveBefore and MoveAfter.

Testing

  • pre-commit run
  • ctest --test-dir build -R '^table_update_test$' --output-on-failure

Comment thread src/iceberg/update/update_schema.cc Resolved

@zhjwpku zhjwpku left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM

Comment thread src/iceberg/update/update_schema.cc Resolved
@wgtmac

wgtmac commented Dec 1, 2026

Copy link
Copy Markdown
Member

Thanks for fixing it! CI failure is unrelated. I'll merge this.

@wgtmac
wgtmac merged commit c2a97c9 into apache:main Dec 1, 2026
14 of 15 checks passed
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.

3 participants