SELECT * FROM JT_City WHERE (REPLACE(sCityName,'/ ','')='North Ari Atoll' AND iProvinceID =North Ari Atoll ) OR (REPLACE(sCityName,'/',' ')='North Ari Atoll' AND iProvinceID =North Ari Atoll);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 'Ari Atoll ) OR (REPLACE(sCityName,'/',' ')='North Ari Atoll' AND iProvinceID =N' at line 1