Re: How about a psql backslash command to show GUCs?

Robert Haas <robertmhaas@gmail.com>

From: Robert Haas <robertmhaas@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Christoph Berg <myon@debian.org>, Pavel Stehule <pavel.stehule@gmail.com>, "David G. Johnston" <david.g.johnston@gmail.com>, Joe Conway <mail@joeconway.com>, Mark Dilger <mark.dilger@enterprisedb.com>, Andrew Dunstan <andrew@dunslane.net>, David Rowley <dgrowleyml@gmail.com>, Alvaro Herrera <alvherre@alvh.no-ip.org>, PostgreSQL Developers <pgsql-hackers@lists.postgresql.org>
Date: 2022-04-09T16:50:23Z
Lists: pgsql-hackers
On Sat, Apr 9, 2022 at 10:31 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Christoph Berg <myon@debian.org> writes:
> > The name has evolved from \dcp over various longer \d-things to the
> > more verbose \dconfig. How about we evolve it even more and just call
> > it \config?
>
> I think people felt that it should be part of the \d family.
> Also, because we have \connect and \conninfo, you'd need to
> type at least five characters before you could tab-complete,
> whereas \dconfig is unique at four (you just need \dco).

Regarding this point, I kind of think that \dconfig is a break with
established precedent, but in a good way. Previous additions have
generally tried to pick some vaguely mnemonic sequence of letters that
somehow corresponds to what's being listed, but you have to be pretty
hard-core to remember what \db and \dAc and \drds do. \dconfig is
probably easier to remember.

-- 
Robert Haas
EDB: http://www.enterprisedb.com



Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Be more careful about GucSource for internally-driven GUC settings.

  2. Fix case sensitivity in psql's tab completion for GUC names.

  3. Further tweak the default behavior of psql's \dconfig.

  4. Tweak the default behavior of psql's \dconfig.

  5. psql: add \dconfig command to show server's configuration parameters.

  6. Allow granting SET and ALTER SYSTEM privileges on GUC parameters.