Re: Psql meta-command conninfo+

Hunaid Sohail <hunaidpgml@gmail.com>

From: Hunaid Sohail <hunaidpgml@gmail.com>
To: Maiquel Grassi <grassi@hotmail.com.br>
Cc: Alvaro Herrera <alvherre@alvh.no-ip.org>, Sami Imseih <samimseih@gmail.com>, "pgsql-hackers@postgresql.org" <pgsql-hackers@postgresql.org>, "David G. Johnston" <david.g.johnston@gmail.com>, Jim Jones <jim.jones@uni-muenster.de>, Tom Lane <tgl@sss.pgh.pa.us>, Nathan Bossart <nathandbossart@gmail.com>, "Imseih (AWS), Sami" <simseih@amazon.com>, Peter Eisentraut <peter@eisentraut.org>, Pavel Luzanov <p.luzanov@postgrespro.ru>, Erik Wienhold <ewie@ewie.name>, Dean Rasheed <dean.a.rasheed@gmail.com>
Date: 2025-01-21T10:17:21Z
Lists: pgsql-hackers
Hi,

On Mon, Jan 20, 2025 at 6:34 PM Maiquel Grassi <grassi@hotmail.com.br>
wrote:

> >That leads me to also wonder why don't we change \conninfo to have this
> >tabular behavior instead of creating a separate command for it.  Why do
> >we need to keep the existing form of \conninfo?  To me it seems strictly
> >less useful, as it is harder to read.
>
> Here, you're suggesting that it would be useful to keep the \conninfo
> meta-command, improve it with a "new version," and display the returned
> content as a table instead of text. If that's the case, I think it's a
> good idea
> since it would show the "new settings" that the current version doesn't
> display and, yes, it would serve the same purpose as \conninfo+.
>

Sure, we can proceed with that. I do hope this will be the final one we try
:)


> Regarding which settings to display, the discussion tends to get very
> broad,
> and we can never settle on what should be shown definitively. I believe
> that, often, less is more, so showing only the essential settings would be
> enough.
>

In that case, we can collectively decide which parameters should be shown
in this command. My suggestion:
- application_name
- encodings (maybe?)
- role (new patch)
- is_superuser
- session_authorization
- in_hot_standby

Feel free to suggest any additions or removals.

Regards,
Hunaid Sohail

Commits

  1. psql: Change new \conninfo to use SSL instead of TLS

  2. Change \conninfo to use tabular format

  3. Update extension lookup routines to use the syscache

  4. Improve COPY TO performance when server and client encodings match

  5. doc: Remove superfluous bracket in synopsis

  6. Remove psql support for server versions preceding 9.2.