Repository navigation
Fix extra whitespace printed before ON CONFLICT - #1037
Merged
alamb merged 1 commit intoNov 20, 2023
Merged
Conversation
CDThomas
marked this pull request as ready for review
November 3, 2023 06:20
lovasoa
approved these changes
Nov 10, 2023
CDThomas
commented
Nov 11, 2023
| " ON DUPLICATE KEY UPDATE {}", | ||
| display_comma_separated(expr) | ||
| ), | ||
| Self::OnConflict(o) => write!(f, " {o}"), |
Contributor
Author
There was a problem hiding this comment.
The bug is that the whitespace here is doubled up with the whitespace added a few lines below: https://github.com/sqlparser-rs/sqlparser-rs/blob/edeb9a2df0c55bf072dcb66b10661987dc926b2d/src/ast/mod.rs#L3522
alamb
approved these changes
Nov 18, 2023
Pull Request Test Coverage Report for Build 6916193631
💛 - Coveralls |
Contributor
|
Looks like there is a CI failure but after that this PR should be good to go Update: the CI failure is related to the new rust release. I think a merge up from main will fix that |
Contributor
|
yes, I included the small lint fix in my previous pr, which is now merged |
CDThomas
force-pushed
the
fix/print-on-conflict-whitespace
branch
from
November 18, 2023 20:46
edeb9a2 to
de2843e
Compare
Contributor
Author
Contributor
CDThomas
added a commit
to cipherstash-archive/sqlparser-rs-original
that referenced
this pull request
Nov 20, 2023
apache#1037 removed the extra whitespace, so we need to remove it here as well now.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I noticed while working on #1036 that there's some extra whitespace printed before
ON CONFLICTclauses in insert statements. This PR should fix it up by removing the extra space in theDisplayimpl.