出现结果重复数SQL(四表关联):
SELECT
COUNT(post.ID )
FROM wp_posts AS post LEFT JOIN
wp_term_relationships AS relation
ON(post.menu_order =
relation.term_order) LEFT JOIN wp_term_taxonomy
AS taxonomy
ON(relation.term_taxonomy_id = taxonomy.term_id) LEFT JOIN
wp_terms AS
term ON(taxonomy.term_id = term.term_id)SELECT
COUNT(post.ID )