MySQL LIKE '%...%' query won't work
#2

Try using a double percentage sign. If you're using format(), you need to escape the percentage sign properly or it'll cause problems.

A single percentage sign in format() is considered as a placeholder, more than 1 will actually show in the string properly.

Код:
SELECT * FROM `help` WHERE `searchWord1` LIKE '%%%s%%' LIMIT 0 , 30
Reply


Messages In This Thread
MySQL LIKE '%...%' query won't work - by tMike - 06.06.2012, 15:01
Re: MySQL LIKE '%...%' query won't work - by Calgon - 06.06.2012, 15:04
AW: MySQL LIKE '%...%' query won't work - by tMike - 06.06.2012, 15:10

Forum Jump:


Users browsing this thread: 1 Guest(s)