Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Export WP tags
SELECT wp_terms.`term_id` AS TagID, wp_terms.`name` AS TagName, SUM( tax.`count` ) AS TagPostCount
FROM `wp_terms`
INNER JOIN wp_term_taxonomy tax ON tax.term_id = wp_terms.term_id
GROUP BY wp_terms.`term_id`;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment