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 'Oc' IN (SELECT value FROM cart_product_extra_field_value WHERE product_id = p.pr' at line 1
Error No: 1064
SELECT COUNT(DISTINCT p.product_id) AS total FROM cart_product p LEFT JOIN cart_product_discount pdis ON p.product_id = pdis.product_id AND pdis.customer_group_id = '8' and pdis.quantity <= '1' AND pdis.date_start <= NOW() AND pdis.date_end >= NOW() LEFT JOIN cart_product_special ps ON p.product_id = ps.product_id AND ps.customer_group_id = '8' AND ps.date_start <= NOW() AND ps.date_end >= NOW() LEFT JOIN cart_product_to_store p2s ON (p.product_id = p2s.product_id) WHERE p.status = '1' AND p2s.store_id = '0' AND p.date_available <= NOW() AND IF(pdis.quantity, pdis.quantity, '1') = '1' AND 'Pays d'Oc' IN (SELECT value FROM cart_product_extra_field_value WHERE product_id = p.product_id AND language_id = '1')