Re: how to list privileges on the database object itself via SQL?

From: Erik Wienhold <ewie(at)ewie(dot)name>
To: richard coleman <rcoleman(dot)ascentgl(at)gmail(dot)com>
Cc: pgsql-admin(at)lists(dot)postgresql(dot)org
Subject: Re: how to list privileges on the database object itself via SQL?
Date: 2023-04-26 18:21:48
Message-ID: 812687998.1203746.1682533308355@office.mailbox.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

> On 26/04/2023 19:53 CEST richard coleman <rcoleman(dot)ascentgl(at)gmail(dot)com> wrote:
>
> Erik,
>
> Thanks for that. I'll have to look into the aclexplode() function some more.
>
> When I try running your SQL on a pg11 database I get:
>
> ERROR: role "role" does not exist
> LINE 3: WHERE grantee = 'role'::regrole AND privilege_type I...
> ^
> SQL state: 42704
> Character: 151

I used 'role'::regrole as example because your has_table_privilege sample uses
that role name. Weird name for a role but I went along with it ;)

--
Erik

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Holger Jakobs 2023-04-26 18:22:56 Re: how to list privileges on the database object itself via SQL?
Previous Message Holger Jakobs 2023-04-26 18:07:50 Re: how to list privileges on the database object itself via SQL?