Can't do SELECT COUNT(idee_sejour_id) FROM idees_sejours WHERE idee_sejour_display_fr = 1 AND idee_sejour_idee_sejour_category_id = , Error :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 '' at line 5