From: | Alexey Klyukin <alexk(at)commandprompt(dot)com> |
---|---|
To: | Akmal Akmalhojaev <akmal(dot)ilh(at)gmail(dot)com> |
Cc: | pgsql-ru-general(at)postgresql(dot)org |
Subject: | Re: Role members |
Date: | 2007-05-21 11:29:02 |
Message-ID: | 4651827E.6080506@commandprompt.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-ru-general |
Добрый день,
Можно попробовать использовать pg_has_role вместе с select, например так:
select rolname from pg_authid where pg_has_role(rolname, 'ID1', 'member');
где ID1 - имя роли, для которой ищуться все роли, входящие в нее.
Akmal Akmalhojaev wrote:
> Hello! I have the following question.
>
> For example I have a role ID1 with members ID2 and ID3.
> Role ID2 has also members ID4 and ID5. It means that roles ID4 and ID5 are
> members of ID1.
> The question: Is there any function in PostgreSQL, that finds all the
> members of role ID1 - even such members, as ID4 and ID5.
>
> Thanks.
>
--
Alexey Klyukin http://www.commandprompt.com/
The PostgreSQL Company - Command Prompt, Inc.
From | Date | Subject | |
---|---|---|---|
Next Message | Akmal Akmalhojaev | 2007-05-25 22:03:49 | Где хранятся привилегии |
Previous Message | Akmal Akmalhojaev | 2007-05-21 10:21:12 | Role members |