Subject Re: how to determine User role
Author ainpoissee
--- In firebird-support@yahoogroups.com, "tony_bat" <tony_bat@...> wrote:
>
> I have three different roles and several users.
> When a user logs in how can I determine which role to use. I realize
> the role must be set at login, but if user does not know role name when
> logging in how can I get role name(s) and then relogin using role
> appropriate role.

Something like

SELECT RDB$RELATION_NAME FROM RDB$USER_PRIVILEGES WHERE(RDB$USER =
UPPER(CURRENT_USER))and(RDB$PRIVILEGE = 'M')

should give you a list of roles granted to the current user.


HTH
ain