Skip to content

Conversation

alamb
Copy link
Contributor

@alamb alamb commented Jan 23, 2025

Which issue does this PR close?

Rationale for this change

Keep up with latest SQL parser dependencies

What changes are included in this PR?

  1. Update to sqlparser to latest released
  2. Update DataFusion to use the latest APIs

Are these changes tested?

Yes by CI

Are there any user-facing changes?

@github-actions github-actions bot added sql SQL Planner logical-expr Logical plan and expressions sqllogictest SQL Logic Tests (.slt) common Related to common crate labels Jan 23, 2025
----
5.000000000 secs

60 mons
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this certainly seems much more correct to me -- I also removed the now out of date comment.

}

fn sql_subscript_to_expr(
fn sql_compound_field_access_to_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.

The code to plan CompoundFieldAccess is directly copy/pasted from @goldmedal 's PR

@alamb alamb changed the title chore(deps): Update sqlparser to 0.54.0 @alamb chore(deps): Update sqlparser to 0.54.0 Jan 24, 2025
@alamb alamb marked this pull request as draft January 24, 2025 08:23
@alamb alamb marked this pull request as ready for review January 27, 2025 17:55
///
/// For example, `foo.bar` would be represented as a two element vector
/// `["foo", "bar"]`
fn from_idents(mut idents: Vec<String>) -> Option<Self> {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Changed the signature to be easier to work with (pass the vec by ownership rather than &mut)

Copy link
Contributor

@goldmedal goldmedal left a comment

Choose a reason for hiding this comment

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

Thanks @alamb. Overall look good to me 👍

Comment on lines +2626 to +2628
# left_join_using_qualified (snowflake syntax)
query error DataFusion error: This feature is not implemented: Invalid identifier in USING clause\. Expected single identifier, got t2\.c2
SELECT t1.c1, t2.c2 FROM test_partition_table t1 JOIN test_partition_table t2 USING (t2.c2) ORDER BY t2.c2;
Copy link
Contributor

Choose a reason for hiding this comment

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

👍

@goldmedal
Copy link
Contributor

@alamb There are some conflicts here.

@alamb
Copy link
Contributor Author

alamb commented Feb 5, 2025

@alamb There are some conflicts here.

Thank you for the review @goldmedal -- I have merged up and resolved the conflicts

@goldmedal goldmedal merged commit 304488d into apache:main Feb 5, 2025
27 checks passed
@goldmedal
Copy link
Contributor

🚀

@alamb
Copy link
Contributor Author

alamb commented May 21, 2025

This appears to have caused a regression:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

common Related to common crate logical-expr Logical plan and expressions sql SQL Planner sqllogictest SQL Logic Tests (.slt)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants