-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
SQLParserUtils::getPlaceholderPositions()
fails if there are quoted strings containing only backslashes
#2720
Conversation
Fixed my bug, but generated another one :) |
@mondrake excellent work, thanks! Looking good to me. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have to admit that I barely understand those crazy regexes but the tests look reasonable to me and I simply trust you guys on this one ;)
LGTM 👍 |
@mondrake just a note - please use more self-explanatory commit messages next time :-) |
Backported to |
Sure 😄 |
SQLParserUtils::getPlaceholderPositions()
fails if there are quoted strings containing only backslashes
Passing the following statement to
SQLParserUtils::getPlaceholderPositions
results in failure to identify the second placeholdercondition_1
.Apparently,
::getUnquotedStatementFragments
gets confused by escapes.Added a test to prove the bug.