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

getSQL issue with consecutive dollar signs ($$) values #684

Closed
janosnagy opened this issue Apr 26, 2018 · 1 comment
Closed

getSQL issue with consecutive dollar signs ($$) values #684

janosnagy opened this issue Apr 26, 2018 · 1 comment
Labels
bug Identified bug which needs a fix
Milestone

Comments

@janosnagy
Copy link

janosnagy commented Apr 26, 2018

If a string type filter has a value that contains consecutive dollar signs (eg. some$$thing) then the expression returned by getSQL will not have the correct number of dollar signs (see. attached image)
image

The reason of this problem that in this

return sql.op.replace('?', v);
replace call the second parameter is specified as a string hence there are some special replacement patterns applied see reference

I am wondering if this replace call can be changed that the second parameter would be a function
return sql.op.replace('?', function(){return v;})
since in this case the special replacement patterns would not apply and the value would be correct in the text returned by getSQL. Thanks.

@mistic100 mistic100 added this to the 2.5.2 milestone Apr 26, 2018
@mistic100 mistic100 added the bug Identified bug which needs a fix label Apr 26, 2018
@janosnagy janosnagy reopened this Apr 27, 2018
@janosnagy
Copy link
Author

Thank you very much for the quick fix. Do you have any planned release date for version 2.5.2?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Identified bug which needs a fix
Projects
None yet
Development

No branches or pull requests

2 participants