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

feat: convert table name to quoted style #454

Merged
merged 6 commits into from
Dec 7, 2022

Conversation

Rachelint
Copy link
Contributor

Which issue does this PR close?

Closes #

Rationale for this change

For #442 .
Now we convert table name to quoted style to prevent datafusion from converting it to lowercase.

What changes are included in this PR?

All changes are in sql/src/parser.rs.
Main steps:

  • extract the table name from select ast.
  • convert it to quoted style.
  • rebuild the select ast.

Are there any user-facing changes?

Table name in ceresdb will be case-sensitive.

How does this change test

Test by ut and integrated test.

@Rachelint Rachelint force-pushed the convert-table-name-quoted-style branch 2 times, most recently from babaf3a to 17a42a9 Compare December 7, 2022 07:14
@Rachelint Rachelint marked this pull request as ready for review December 7, 2022 07:14
@Rachelint Rachelint force-pushed the convert-table-name-quoted-style branch 3 times, most recently from 491cae6 to 2cf3c3c Compare December 7, 2022 07:22
@Rachelint Rachelint force-pushed the convert-table-name-quoted-style branch 2 times, most recently from 499e6ae to f37b27e Compare December 7, 2022 08:58
@Rachelint Rachelint force-pushed the convert-table-name-quoted-style branch from f37b27e to 2ec396c Compare December 7, 2022 09:14
Copy link
Member

@ShiKaiWi ShiKaiWi left a comment

Choose a reason for hiding this comment

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

LGTM

@Rachelint Rachelint force-pushed the convert-table-name-quoted-style branch from 2ec396c to 15bcd41 Compare December 7, 2022 09:37
@ShiKaiWi ShiKaiWi merged commit d1642e7 into apache:main Dec 7, 2022
chunshao90 pushed a commit to chunshao90/ceresdb that referenced this pull request May 15, 2023
* convert table name to quoted style in sql statement.

* add unit test.

* revert pr444(apache#444).

* refactor related integration tests.

* remove useless commets.

* refactor the way of extracting table name.
@Rachelint Rachelint deleted the convert-table-name-quoted-style branch May 27, 2023 12:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants