From: Adrian Klaver <adrian.klaver@aklaver.com>
To: Pawan Sharma <pawanpg0963@gmail.com>
To: " <pgsql-general@postgresql.org>
Subject: Re:
Date: Wed, 29 May 2019 07:20:12 -0700
Message-ID: <2b9280b6-8fe9-8b5f-337c-cd32fa26201b@aklaver.com> (raw)
In-Reply-To: <CAKqG8NU1r86sbfk_4zey6Moj5n+VSs2k9P5RKM1_FTPqWSrJ-A@mail.gmail.com>
References: <CAKqG8NU1r86sbfk_4zey6Moj5n+VSs2k9P5RKM1_FTPqWSrJ-A@mail.gmail.com>
On 5/29/19 1:03 AM, Pawan Sharma wrote:
> Hello All,
>
> Is it possible check privileges of all the users or roles, and what are
> the objects owned by user and role with their privileges.
>
> I am getting the output which want from
> information_schema.roles_usage_grants, but as I not running the query as
> a superuser so I am able to see only one specific user results but I
> want all user and roles details.
Are you sure?
information_schema.roles_usage_grants is a view over
information_schema.usage_privileges which only covers the USAGE
privilege. This privilege is restricted to a subset of objects. Look in
the object_type column.
My guess is you are going to end up using the system catalogs:
https://www.postgresql.org/docs/11/catalogs.html
Can you be more specific about the information you are looking for?
>
> Is there specific privileges which I can grant to that user to get the
> complete results apart from superuser privilege.
>
>
> Thanks in advance
> Regards,
> Pawan
--
Adrian Klaver
adrian.klaver@aklaver.com
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-general@postgresql.org
Cc: adrian.klaver@aklaver.com, pawanpg0963@gmail.com
Subject: Re:
In-Reply-To: <2b9280b6-8fe9-8b5f-337c-cd32fa26201b@aklaver.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox