Skip to content

Instantly share code, notes, and snippets.

@chrispian
Created June 6, 2019 23:29
Show Gist options
  • Save chrispian/93d24a7b31532a24cded99e100b72c82 to your computer and use it in GitHub Desktop.
Save chrispian/93d24a7b31532a24cded99e100b72c82 to your computer and use it in GitHub Desktop.
SELECT COUNT(*) as Days, DATE_FORMAT( post_date_gmt, '%M %D, %Y' ) as pub_date FROM `wp_posts` where `post_status` = 'publish' AND post_type = 'post' GROUP BY pub_date;
@chrispian
Copy link
Author

The total # returned will be the number of days you published. If you published multiple per day you'll see those totals as the results.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment