Re: - Mailing list pgsql-general

From Adrian Klaver
Subject Re:
Date
Msg-id 2b9280b6-8fe9-8b5f-337c-cd32fa26201b@aklaver.com
Whole thread Raw
In response to  (Pawan Sharma <pawanpg0963@gmail.com>)
List pgsql-general
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



pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: with and trigger
Next
From: a venkatesh
Date:
Subject: Re: Query reg. postgresql 9.6 migration from ubuntu 16.04 to 18.04