Skip to content

Union with conflicting metadata fails as logical/physical stages merge it differently #26880

Closed

Description

@AdamGS

Describe the bug

When union fields have metadata, the physical and logical layer merge them in different ways, which might result in different schemas.

To Reproduce

SELECT with_metadata(1, 'id', '1') UNION SELECT with_metadata(NULL, 'id', '2');

returns:

Internal error: Physical input schema should be the same as the one converted from logical input schema. Differences:
	- field metadata at index 0 [with_metadata(Int64(1),Utf8("id"),Utf8("1"))]: (physical) {"id": "1"} vs (logical) {"id": "2"}.

Expected behavior

field metadata merging should be uniform and return the expected results.

Additional context

No response

Willingness to contribute

None

Activity

  1. added theissue type on Oct 29, 2026
  2. AdamGS commented on Oct 29, 2026

    @AdamGS
    ContributorAuthor

    take

  3. added a commit that references this issue on Oct 29, 2026
    a4d71ff
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions