Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add as_decimal_array(arr: &dyn Array) -> &DecimalArray #1312

Closed
alamb opened this issue Feb 15, 2022 · 3 comments · Fixed by #1356
Closed

Add as_decimal_array(arr: &dyn Array) -> &DecimalArray #1312

alamb opened this issue Feb 15, 2022 · 3 comments · Fixed by #1356
Assignees
Labels
arrow Changes to the arrow crate enhancement Any new improvement worthy of a entry in the changelog good first issue Good for newcomers

Comments

@alamb
Copy link
Contributor

alamb commented Feb 15, 2022

Is your feature request related to a problem or challenge? Please describe what you are trying to do.
There are many as_XXX functions such as as_boolean_array to conveniently downcast arrays to the appropriate concrete Array types, but not one for DecimalArray 😢 .

The full list of supported ones is in the doc https://docs.rs/arrow/9.0.2/arrow/array/index.html#functions)

Describe the solution you'd like
I would like one for DecimalArray:

fn as_decimal_array(arr: &dyn Array) -> &DecimalArray {
...
}

Additional context
Context: I found while working on apache/datafusion#1475

@alamb alamb added the enhancement Any new improvement worthy of a entry in the changelog label Feb 15, 2022
@alamb
Copy link
Contributor Author

alamb commented Feb 15, 2022

cc @liukun4515

@alamb alamb added arrow Changes to the arrow crate good first issue Good for newcomers labels Feb 15, 2022
@liukun4515
Copy link
Contributor

cc @liukun4515

If no one takes this, I am glad to do this task.
@alamb Please assign it to me.

@liukun4515
Copy link
Contributor

liukun4515 commented Feb 17, 2022

I will do this on the weekend, and focus on some knowledge about ballista and distributed scheduler recently.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
arrow Changes to the arrow crate enhancement Any new improvement worthy of a entry in the changelog good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants