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 '[!db.pre!]enewsztinfo WHERE classid='8' AND id='97399' LIMIT 1' at line 1 SELECT ztid FROM [!db.pre!]enewsztinfo WHERE classid='8' AND id='97399' LIMIT 1