public inbox for [email protected]
help / color / mirror / Atom feedFrom: David G. Johnston <[email protected]>
To: Ayush Vatsa <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: Understanding ALTER DEFAULT PRIVILEGES Behavior in PostgreSQL
Date: Tue, 4 Feb 2025 12:00:38 -0700
Message-ID: <CAKFQuwYEwYezVX4RAiszedMo5Zv-nd-VY0Ab=5GDzsNQpMeyQQ@mail.gmail.com> (raw)
In-Reply-To: <CACX+KaPVTfcmt__Ogwsf7xomtcCABktiA8iSJ+iCxOdbzKNnUA@mail.gmail.com>
References: <CACX+KaPVTfcmt__Ogwsf7xomtcCABktiA8iSJ+iCxOdbzKNnUA@mail.gmail.com>
On Tuesday, February 4, 2025, Ayush Vatsa <[email protected]> wrote:
>
> postgres=# ALTER DEFAULT PRIVILEGES IN SCHEMA my_schema REVOKE EXECUTE ON
> FUNCTIONS FROM PUBLIC;
> ALTER DEFAULT PRIVILEGES
>
As the documentation explains:
Default privileges that are specified per-schema are added to whatever the
global default privileges are for the particular object type. This means
you cannot revoke privileges per-schema if they are granted globally
(either by default, or according to a previous ALTER DEFAULT PRIVILEGES command
that did not specify a schema). Per-schema REVOKE is only useful to reverse
the effects of a previous per-schema GRANT.
David J.
view thread (3+ messages) latest in thread
reply
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: [email protected]
Cc: [email protected], [email protected], [email protected]
Subject: Re: Understanding ALTER DEFAULT PRIVILEGES Behavior in PostgreSQL
In-Reply-To: <CAKFQuwYEwYezVX4RAiszedMo5Zv-nd-VY0Ab=5GDzsNQpMeyQQ@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox