WordPress.org

Support

Support » Plugins and Hacks » [Resolved] How to query user role directly in wp_users table?

[Resolved] How to query user role directly in wp_users table?

  • I want to query users who registered longer than 30 days ago and exclude anyone who is not a subscriber. So the query will always return subscribers.

    How can this be achieved considering the wp_capabilities column in the wp_users table is a serialized array?

    I did try WHERE wp_capabilities LIKE “%subscriber%” however they stated it does not work.

    Thanks folks have a nice day.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘[Resolved] How to query user role directly in wp_users table?’ is closed to new replies.
Skip to toolbar