I'm designing a site in drupal and have a need to get a list of all users of a certain role. I took a look at the database and noticed the role information is lumped into the data field. I only know how to do basic SQL queries, so can anybody give me an example of a SQL query that will return all users of a certain role?

Thanks so much,
Mitch

Comments

no_idea_yet’s picture

G'day Mitch

Haven't used it myself but perhaps this will do what you need http://drupal.org/project/members

H

Jedi Stannis’s picture

Thanks! I was able to look at this code and figure out how to do what I want.

venkat-rk’s picture

If you only want to get this list in the admin area (AFAIK), try the UserLists module:
http://drupal.org/node/34261