I would like to run a simple query to get all users of a particular role, the problem is user roles are stored in bitwise numbers using power of 2 pattern.
For example the roles table is.
1 role one
2 role two...
4
8
16
In a user table we have
username other columns roles
billy .... 192949
I’m not sure how to query for a role like that…
For a single role:
Or a member of all multiple roles
(I’m assuming SQL Server but will be very similar for other flavours)