On Sun, Oct 20, 2024, at 12:14, Alvaro Herrera wrote:
> I think the function calls should be in the FROM clause, and restrict the
> pg_shdepend rows to only the ones in the current database:

Cool. I assume pg_ownerships should be changed in the same way?
New patch attached.

> Now, depending on pg_shdepend for this means that you don't report
> anything for an object until a GRANT to another user has been executed.
> For example if you REVOKE some priv from the object owner, nothing is
> shown until a GRANT is done for another user (and at that point onwards,
> privs by the owner are shown).  This seems less than ideal, but I'm not
> sure how to do different, other than ditching the use of pg_shdepend
> entirely.

Hmm, yeah that's a bit awkward. Maybe okay if clearly documented.

/Joel


Attachment: v3-0001-Add-pg_ownerships-and-pg_privileges-system-views.patch
Description: Binary data

Reply via email to