You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Example that reproduces the problem uploaded to Github
Full description of the issue provided (see below)
Steps to Reproduce
@Query("SELECT * FROM person WHERE name = :names1 or name IN(:names3) or name IN(:names0) or (:name4 = name)")
List<Person> queryNames(List<String> names0, String names1, List<String> names2, List<String> names3, String name4);
Above query doesn't work because of the (:name4 part.
We also added this query as a test in this relevant PR.
Expected Behaviour
Query should successfully run as expected.
Actual Behaviour
Throws an sql syntax error.
Pattern VARIABLE_PATTERN = Pattern.compile("[^:](:([a-zA-Z0-9]+))");
The above pattern matches the character just before : and later we replace the pattern with: query = matcher.replaceAll(" ?");
Therefore destroying the pattern.
Environment Information
Example Application
The text was updated successfully, but these errors were encountered:
Task List
Steps to Reproduce
Above query doesn't work because of the
(:name4
part.We also added this query as a test in this relevant PR.
Expected Behaviour
Query should successfully run as expected.
Actual Behaviour
Throws an sql syntax error.
Pattern VARIABLE_PATTERN = Pattern.compile("[^:](:([a-zA-Z0-9]+))");
The above pattern matches the character just before
:
and later we replace the pattern with:query = matcher.replaceAll(" ?");
Therefore destroying the pattern.
Environment Information
Example Application
The text was updated successfully, but these errors were encountered: