Re: Psql meta-command conninfo+ - Mailing list pgsql-hackers

From Hunaid Sohail
Subject Re: Psql meta-command conninfo+
Date
Msg-id CAMWA6yY2UpavEzbEbsFw3ie4S6Q2m_CsJyHfLS9i99XzJFxtAQ@mail.gmail.com
Whole thread Raw
In response to RE: Psql meta-command conninfo+  (Maiquel Grassi <grassi@hotmail.com.br>)
Responses Re: Psql meta-command conninfo+
List pgsql-hackers
Hi,

On Thu, Oct 3, 2024 at 1:39 PM Maiquel Grassi <grassi@hotmail.com.br> wrote:
>I thought it would be nice to have a description that tells how both
>Session and Authenticated users differ. IMHO *only* a reference to
>PQuser() doesn't say much, but others might be ok with it. So let's see
>what the other reviewers say.

Hi everyone,
I believe the difference between Session and Authenticated
users should indeed be made clearer, while still keeping
PQuser() in the description. 

Based on my readings from the documentation [1] and [2], we can update user descriptions as follows:

Authenticated User: The name of the user returned by PQuser(), indicating the user who initiated or authenticated the current database connection.
Session User: The session user's name, which is initially the same as the authenticated user but can be changed with SET SESSION AUTHORIZATION. See the session_user() function in <xref linkend="functions-info-session-table"/> for more details.

Let me know if this is fine, then I can provide a new patch.


Regards,
Hunaid Sohail
 

pgsql-hackers by date:

Previous
From: Peter Smith
Date:
Subject: Re: Pgoutput not capturing the generated columns
Next
From: "David G. Johnston"
Date:
Subject: Re: Psql meta-command conninfo+