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 'all OR showCatIDs like '%|multiselect-all|%' OR catID = 53 OR showCatIDs like '%' at line 1select * from urun where urun.bakiyeOdeme=0 AND urun.active = 1 AND urun.active = 1 AND (catID = multiselect-all OR showCatIDs like '%|multiselect-all|%' OR catID = 53 OR showCatIDs like '%|53|%' OR catID = 51 OR showCatIDs like '%|51|%' OR catID = 52 OR showCatIDs like '%|52|%' OR catID = 54 OR showCatIDs like '%|54|%' OR catID = 63 OR showCatIDs like '%|63|%' OR catID = 69 OR showCatIDs like '%|69|%' OR catID = 60 OR showCatIDs like '%|60|%' OR catID = 64 OR showCatIDs like '%|64|%' OR catID = 58 OR showCatIDs like '%|58|%' OR catID = 57 OR showCatIDs like '%|57|%' OR catID = 55 OR showCatIDs like '%|55|%' OR catID = 65 OR showCatIDs like '%|65|%' OR catID = 70 OR showCatIDs like '%|70|%' OR catID = 68 OR showCatIDs like '%|68|%' OR catID = 66 OR showCatIDs like '%|66|%' OR catID = 61 OR showCatIDs like '%|61|%' OR catID = 67 OR showCatIDs like '%|67|%' OR catID = 56 OR showCatIDs like '%|56|%' OR catID = 59 OR showCatIDs like '%|59|%' OR catID = 32 OR showCatIDs like '%|32|%' OR catID = 62 OR showCatIDs like '%|62|%' OR ID=0 ) order by urun.seq desc limit 0,999