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

Greg Stark <stark@mit.edu>

From: Greg Stark <stark@mit.edu>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>, Mark Dilger <mark.dilger@enterprisedb.com>
Date: 2022-04-06T18:45:31Z
Lists: pgsql-hackers
On Wed, 6 Apr 2022 at 13:50, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>
> when I want to see some related parameters, or when I'm a bit
> fuzzy on the exact name of the parameter.  Not only is this
> a lot of typing, but unless I'm willing to type even more to
> avoid using "*", I'll get a wall of mostly unreadable text,
> because pg_settings is far too wide and cluttered with
> low-grade information.

I may be suffering from some form of the Mandela Effect but I have a
distinct memory that once upon a time SHOW actually took patterns like
\d does. I keep trying it, forgetting that it doesn't actually work.
I'm guessing my brain is generalizing and assuming SHOW fits into the
same pattern as \d commands and just keeps doing it even after I've
learned repeatedly that it doesn't work.

Personally I would like to just make the world match the way my brain
thinks it is and make this just work:

SHOW enable_*

I don't see any value in allowing * or ? in GUC names so I don't even
see a downside to this. It would be way easier to discover than
another \ command

-- 
greg



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.