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

Regression with coalesce expr_fn function: can't take multiple arguments #10320

Closed
alamb opened this issue Apr 30, 2024 · 0 comments · Fixed by #10321
Closed

Regression with coalesce expr_fn function: can't take multiple arguments #10320

alamb opened this issue Apr 30, 2024 · 0 comments · Fixed by #10321
Assignees
Labels
bug Something isn't working regression Something that used to work no longer does

Comments

@alamb
Copy link
Contributor

alamb commented Apr 30, 2024

Describe the bug

Previously it could be called with multiple expressions like coalsce(vec![e1, e2]) however now it seems to require a single expressions

To Reproduce

Try to run coalsce(vec![e1, e2])

  --> iox_query_influxql/src/plan/planner_rewrite_expression.rs:327:58
    |
327 |                         Operator::Divide => yes(coalesce(vec![expr, lit(0_f64)])),
    |                                                 -------- ^^^^^^^^^^^^^^^^^^^^^^ expected `Expr`, found `Vec<Expr>`
    |                                                 |
    |                                                 arguments to this function are incorrect
    |
    = note: expected enum `datafusion::prelude::Expr`
             found struct `std::vec::Vec<datafusion::prelude::Expr>`

Expected behavior

We should be able to call it with multiple arguments

Additional context

@appletreeisyellow found this while updating InfluxDB IOx to the latest DataFusion version and identified the upstream PR #10201 / fe268bc brought in a regression.

@alamb alamb added the bug Something isn't working label Apr 30, 2024
@alamb alamb self-assigned this Apr 30, 2024
@alamb alamb added the regression Something that used to work no longer does label May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working regression Something that used to work no longer does
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant