Support » Themes and Templates » Get Last x Unique Author IDs

  • Resolved nandanjha


    I run a multi-author blog. Requesting Help.

    I want to show Gravatar + ‘no of posts’ of recent x unique authors. It might happen that recent x posts are by same authors. So we do not need authors of last x posts. What I am looking for is that

    – to show x recent unique authors and they could be from last y posts or z posts.

    Big thanks in advance.

Viewing 1 replies (of 1 total)
  • Following seems to be working. thanks.

    select post_author, max(post_date) as postdate from wp_posts where post_type = ‘post’ and post_status=’publish’ group by post_author order by postdate desc limit 5

Viewing 1 replies (of 1 total)
  • The topic ‘Get Last x Unique Author IDs’ is closed to new replies.