Support for casting StringViewArray to DecimalArray#6720
Merged
alamb merged 4 commits intoapache:masterfrom Nov 16, 2024
Merged
Support for casting StringViewArray to DecimalArray#6720alamb merged 4 commits intoapache:masterfrom
StringViewArray to DecimalArray#6720alamb merged 4 commits intoapache:masterfrom
Conversation
Signed-off-by: Tai Le Manh <[email protected]>
Omega359
reviewed
Nov 12, 2024
arrow-cast/src/cast/mod.rs
Outdated
| Ok(Arc::new(byte_array_builder.finish())) | ||
| } | ||
|
|
||
| trait StringArrayType<'a>: ArrayAccessor<Item = &'a str> + Sized { |
Contributor
There was a problem hiding this comment.
We would now have this in arrow-string and arrow-cast. Perhaps this would be best moved to arrow-array alongside ArrayAccessor ?
Contributor
Author
There was a problem hiding this comment.
@Omega359 Thanks so much for reviewing.
We would now have this in arrow-string and arrow-cast. Perhaps this would be best moved to arrow-array alongside ArrayAccessor ?
Makes sense to me 👍
Signed-off-by: Tai Le Manh <[email protected]>
StringViewArray to DecimalArray
alamb
reviewed
Nov 15, 2024
| unsafe fn value_unchecked(&self, index: usize) -> Self::Item; | ||
| } | ||
|
|
||
| /// A trait for Arrow String Arrays, currently three types are supported: |
Contributor
There was a problem hiding this comment.
This is nice to start making public -- we use it in DataFusion a bit as well, so starting to consolidate on a single implementation will be good
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which issue does this PR close?
Closes #6715.
Rationale for this change
What changes are included in this PR?
Utf8View) to numeric(Int/Float/Decimal).Are there any user-facing changes?
No.