Skip to content

support for automatic value promotion for aggregation functions #551

@jimexist

Description

@jimexist

Is your feature request related to a problem or challenge? Please describe what you are trying to do.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
(This section helps Arrow developers understand the context and why for this feature, in addition to the what)

for now,

select sum(c5) from test;

will err:

> select sum(c5) from test;
thread 'tokio-runtime-worker' panicked at 'attempt to add with overflow', /Users/jiayu_liu/.rustup/toolchains/stable-x86_64-apple-darwin/lib/rustlib/src/rust/library/core/src/ops/arith.rs:107:1
ArrowError(ExternalError(Canceled))

even avg will do the same because it depends on sum.

Describe the solution you'd like
A clear and concise description of what you want to happen.

have automatic value promotion into wider type

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions