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

Update to sqlparser 0.14 #1796

Merged
merged 4 commits into from
Feb 11, 2022
Merged

Conversation

alamb
Copy link
Contributor

@alamb alamb commented Feb 9, 2022

Draft until sqlparser 0.14 is actually released

Which issue does this PR close?

Closes #1804

Rationale for this change

A new version of sqlparser is about to be released, and this PR serves as potential QA for this effort

What changes are included in this PR?

  1. Update sqlparser version
  2. update datafusion sqlparser for new changes

Are there any user-facing changes?

New dependency and some new SQL syntax support

@github-actions github-actions bot added ballista datafusion Changes in the datafusion crate sql SQL Planner labels Feb 9, 2022
FunctionArg::Unnamed(arg) => arg,
};

match arg {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needed due to apache/datafusion-sqlparser-rs#378 from @panarch (so we don't allow crazy stuff like SELECT * + * from foo 👍

expr: Box::new(expr),
key: plan_key(key),
}
fn plan_indexed(expr: Expr, mut keys: Vec<SQLExpr>) -> Result<Expr> {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had to change this code anyways to handle arbitrary expressions due to apache/datafusion-sqlparser-rs#382 so I took the time to remove the clippy warning too

@alamb alamb force-pushed the alamb/test_update_sqlparser branch from 209b70e to dc360f5 Compare February 9, 2022 17:24
@alamb alamb marked this pull request as ready for review February 9, 2022 19:03
@alamb alamb requested a review from jimexist February 11, 2022 11:18
@alamb
Copy link
Contributor Author

alamb commented Feb 11, 2022

I think it might be nice to update to latest sqlparser before the 7.0.0 release

Copy link
Member

@xudong963 xudong963 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, I also think it would be better to join 7.0.0

@alamb
Copy link
Contributor Author

alamb commented Feb 11, 2022

Thanks @xudong963

@alamb alamb merged commit 0a50dcd into apache:master Feb 11, 2022
@alamb alamb deleted the alamb/test_update_sqlparser branch August 8, 2023 20:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
datafusion Changes in the datafusion crate sql SQL Planner
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants