From: Laurenz Albe <laurenz.albe@cybertec.at>
To: Max Ziermann <max.ziermann@htw-dresden.de>
To: pgsql-docs@lists.postgresql.org
Subject: Re: Triggers on underlying tables of updatable views
Date: Wed, 01 Dec 2021 22:17:00 +0100
Message-ID: <b1100fff9b075856614cf2116f8854c55c5d8720.camel@cybertec.at> (raw)
In-Reply-To: <c81b4639-1f77-3454-401b-eed00b02efb6@htw-dresden.de>
References: <163758281947.26190.10251137266467665332@wrigleys.postgresql.org>
<2f54dbb7d59aacacbc4654b0bc56faaebe993e09.camel@cybertec.at>
<3e14b477-40ce-4b6a-047a-9fea3843427c@htw-dresden.de>
<cde3a45c440fd64884565725fc6f98b6dae8446d.camel@cybertec.at>
<c36ec1311c8ded32bef4dd95dda6dba4f5ca65ff.camel@cybertec.at>
<c81b4639-1f77-3454-401b-eed00b02efb6@htw-dresden.de>
On Wed, 2021-12-01 at 21:34 +0100, Max Ziermann wrote:
> I'm not sure where in the docs a clarification could best be placed. For
> me, the confusion arises from the fact that the updatable views section
> on the CREATE VIEW docs aren't very clear what *actually* happens when
> performing insert/update etc. through a view. It seems like the
> distinction between "security context" and the actual user might be
> helpful to understand the behaviour.
>
> With this background in mind, I still think that the wording "the user
> performing the update does not need ANY permissions on the underlying
> base relations" (from CREATE VIEW; emphasis mine) is misleading.
> However, to me, it would be perfectly fine if this statement was scoped
> to the actual insert/update on the base relation, thus excluding
> triggered functions (unless SECURITY DEFINERs).
You could send a documentation patch with your suggested wording.
I agree that some more detail could be helpful.
Yours,
Laurenz Albe
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: pgsql-docs@postgresql.org
Cc: laurenz.albe@cybertec.at, max.ziermann@htw-dresden.de, pgsql-docs@lists.postgresql.org
Subject: Re: Triggers on underlying tables of updatable views
In-Reply-To: <b1100fff9b075856614cf2116f8854c55c5d8720.camel@cybertec.at>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox