HuaHuaY opened a new pull request, #10417: URL: https://github.com/apache/arrow-rs/pull/10417
# Which issue does this PR close? Closes #10416. # Rationale for this change Arrow allows mapping Uint8/16/32 to Parquet types Int16/32/64. However, the current code does not support this. Arrow's documentation: https://arrow.apache.org/docs/format/CanonicalExtensions.html#primitive-type-mappings # What changes are included in this PR? - Support `UInt8`, `UInt16`, and `UInt32` Arrow Variant `typed_value` fields. - Continue rejecting unsigned types in Parquet Variant schemas. - **Add lossless `UInt32` Arrow array to Parquet `INT64` writer coercion** # Are these changes tested? Yes. # Are there any user-facing changes? `VariantArray` and `shred_variant` now support canonical `UInt8`/`UInt16`/`UInt32` `typed_value` fields. **`ArrowWriter` can also write `UInt32` arrays to `INT64` columns when using a compatible custom Parquet schema.** This is because it's not convenient to distinguish whether the column is in a variant within the context of `arrow_writer/mod.rs`. I think this is a side effect of this PR; please point out any better suggestions. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
