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

Array literals do not work in generated fields #697

Open
mwylde opened this issue Jul 30, 2024 · 0 comments
Open

Array literals do not work in generated fields #697

mwylde opened this issue Jul 30, 2024 · 0 comments
Labels
bug Something isn't working sql Related to the DataFusion SQL integration

Comments

@mwylde
Copy link
Member

mwylde commented Jul 30, 2024

This query fails in planning:

create table input (
    length JSON,
    diff INT GENERATED ALWAYS AS (extract_json(length, '$.old')[1]) STORED
) with (
    connector = 'sse',
    endpoint = 'https://localhost:9091',
    format = 'json'
);

with the error

internal error: entered unreachable code: ListIndex should be rewritten in OperatorToFunction panic.file="/Users/mwylde/.cargo/git/checkouts/arrow-datafusion-152f78fee6ec2290/ca898b0/datafusion/physical-expr/src/planner.rs" panic.line=233 panic.column=21

It appears that a necessary optimization is not being run on generated field SQL

@mwylde mwylde added bug Something isn't working sql Related to the DataFusion SQL integration labels Jul 30, 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 sql Related to the DataFusion SQL integration
Projects
None yet
Development

No branches or pull requests

1 participant