Skip to content

[Variant] Support Binary/LargeBinary children #9610

Open
AdamGS wants to merge 1 commit intoapache:mainfrom
AdamGS:adamg/variant-all-binary-children
Open

[Variant] Support Binary/LargeBinary children #9610
AdamGS wants to merge 1 commit intoapache:mainfrom
AdamGS:adamg/variant-all-binary-children

Conversation

@AdamGS
Copy link
Copy Markdown
Contributor

@AdamGS AdamGS commented Mar 24, 2026

Which issue does this PR close?

Rationale for this change

Improves spec compliance and improves performance, allowing more zero-copy copies between parquet and/or other implementation.

What changes are included in this PR?

The main change is replacing VariantArray's children with opaque ArrayRef, and handling validation accordingly.

Are these changes tested?

All existing tests are still in place.

Are there any user-facing changes?

Yes, some functions on VariantArray now take or return ArrayRef, from_parts, value_field, metadata_field.

Signed-off-by: Adam Gutglick <adam@spiraldb.com>
@github-actions github-actions bot added the parquet-variant parquet-variant* crates label Mar 24, 2026
Comment on lines +484 to +488
impl PartialEq for VariantArray {
fn eq(&self, other: &Self) -> bool {
self.inner == other.inner
}
}
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

This replaces the derived implementation, I think it should be correct as all other members are derived from it.

@sdf-jkl
Copy link
Copy Markdown
Contributor

sdf-jkl commented Mar 27, 2026

LGTM, this will be useful for #8354.

@scovich please take a look

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

Labels

parquet-variant parquet-variant* crates

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Variant] Support BinaryArray/LargeBinaryArray in addition to BinaryViewArray for Variant

2 participants