Skip to content

Support the string concat operator #178

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

Merged
merged 2 commits into from
Jun 2, 2020
Merged

Conversation

Dandandan
Copy link
Contributor

@Dandandan Dandandan commented Jun 1, 2020

Adds support for string concatenation operator || https://github.com/andygrove/sqlparser-rs/issues/160

Support the string concat operator
Copy link
Contributor

@nickolay nickolay left a comment

Choose a reason for hiding this comment

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

Looks good to me, apart from the typo noted in a separate comment.

Thanks!

src/tokenizer.rs Outdated
Comment on lines 384 to 386
// a regular '/' operator
_ => Err(TokenizerError(format!(
"Tokenizer Error at Line: {}, Col: {}",
Copy link
Contributor

Choose a reason for hiding this comment

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

The reference to '/' is presumably a typo. This should probably say we don't support the single-pipe | token (bitwise OR in some dialects, but not part of the standard)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Made some modifications to the error message.

Probably, it would be useful though to support | too.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Also, another improvement would be to include a simple function which adds line/column information in a consistent way.

Copy link
Contributor

Choose a reason for hiding this comment

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

Probably, it would be useful though to support | too.

Yes, I see no reason not to.

include a simple function which adds line/column information in a consistent way.

Agreed. I see you filed #179 about that.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes :)

@nickolay nickolay merged commit 00dc490 into apache:master Jun 2, 2020
@nickolay
Copy link
Contributor

nickolay commented Jun 2, 2020

Thanks!

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