Re: Add pg_get_acl() function get the ACL for a database object
Isaac Morland <isaac.morland@gmail.com>
From: Isaac Morland <isaac.morland@gmail.com>
To: Joel Jacobson <joel@compiler.org>
Cc: pgsql-hackers@postgresql.org
Date: 2024-06-19T14:23:45Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Add pg_get_acl() to get the ACL for a database object
- 4564f1cebd43 18.0 landed
-
doc: Add ACL acronym for "Access Control List"
- 00d819d46a6f 18.0 cited
On Wed, 19 Jun 2024 at 07:35, Joel Jacobson <joel@compiler.org> wrote:
> Hello hackers,
>
> Currently, obtaining the Access Control List (ACL) for a database object
> requires querying specific pg_catalog tables directly, where the user
> needs to know the name of the ACL column for the object.
>
I have no idea how often this would be useful, but I wonder if it could
work to have overloaded single-parameter versions for each of regprocedure
(pg_proc.proacl), regclass (pg_class.relacl), …. To call, just cast the OID
to the appropriate reg* type.
For example: To get the ACL for table 'example_table', call pg_get_acl
('example_table'::regclass)