Shop

WordPress database 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 'AND t2.taxonomy = 'product_tag' AND p2.post_status = 'publish' AND p1.ID = p2.' at line 13]
SELECT DISTINCT terms2.name,terms2.slug FROM prov_posts as p1 LEFT JOIN prov_term_relationships as r1 ON p1.ID = r1.object_ID LEFT JOIN prov_term_taxonomy as t1 ON r1.term_taxonomy_id = t1.term_taxonomy_id LEFT JOIN prov_terms as terms1 ON t1.term_id = terms1.term_id, prov_posts as p2 LEFT JOIN prov_term_relationships as r2 ON p2.ID = r2.object_ID LEFT JOIN prov_term_taxonomy as t2 ON r2.term_taxonomy_id = t2.term_taxonomy_id LEFT JOIN prov_terms as terms2 ON t2.term_id = terms2.term_id WHERE t1.taxonomy = 'product_cat' AND p1.post_status = 'publish' AND terms1.term_id = AND t2.taxonomy = 'product_tag' AND p2.post_status = 'publish' AND p1.ID = p2.ID