I want to write this query:
SELECT * FROM products
WHERE name LIKE '%?%'
OR description LIKE '%?%'
and execute it through java in spring web application. But here problem is when I use LIKE operator it has to be with literals, but when I write '%?%' java doesn't recognize ? like placeholders for parameters, when I add parameters I get error that there is no parameters in my query.
Also if I write %?% without literals I get syntax error.