I am attempting to use ILIKE with wildcard matching. I have simplified the query to the following for troubleshooting purposes:
select * from table1 where column1 LIKE {{'%' + textinput6.value + '%' }};
I have tried the above with and without the wildcard matching. I have also tried ILIKE as well as LIKE (db is mysql). However, I keep getting the following error:
ER_PARSE_ERROR: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
Similar issue without the like. Just a simple query.
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '?' at line 1
select column1, column2 from mytable WHERE column2 < {{ input1.value }}
the value is an integer as it should be. Why am I getting this error?
Hey @Tess. Yes, I checked this box after posting this and it worked, I just didn't come back and update the forum.
I will say, it's a bit tricky to get some of the MySQL Queries working in this manner, but seems to work nonetheless.
Hi @Greg_J! Glad that solved it! We typically recommend keeping it un-checked unless you really need to disable the setting (for security reasons). In cases where it solves issues with queries, we often recommend setting up another copy of a resource with that setting enabled to help limit the surface area that you have to keep in mind SQL injection for.