Re: Things I don't like about \du's "Attributes" column - Mailing list pgsql-hackers

From Robert Haas
Subject Re: Things I don't like about \du's "Attributes" column
Date
Msg-id CA+TgmoaSgT9AxByNgxz+p1OWoJGsr7xEbEZfwar4XPBnrb+NKg@mail.gmail.com
Whole thread Raw
In response to Things I don't like about \du's "Attributes" column  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Things I don't like about \du's "Attributes" column
List pgsql-hackers
On Thu, Jun 22, 2023 at 8:50 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
> * It seems weird that some attributes are described in the negative
> ("Cannot login", "No inheritance").  I realize that this corresponds
> to the defaults, so that a user created by CREATE USER with no options
> shows nothing in the Attributes column; but I wonder how much that's
> worth.  As far as "Cannot login" goes, you could argue that the silent
> default ought to be for the properties assigned by CREATE ROLE, since
> the table describes itself as "List of roles".  I'm not dead set on
> changing this, but it seems like a topic that deserves a fresh look.

I wonder if we shouldn't try to display the roles's properties using
SQL keywords rather than narrating. Someone can be confused by "No
connections" but "CONNECTION LIMIT 0" is pretty hard to mistake;
likewise "LOGIN" or "NOLOGIN" seems clear enough. If we took this
approach, there would still be a question in my mind about whether to
show values where the configured value of the property matches the
default, and maybe we would want to do that in some cases and skip it
in others, or maybe we would end up with a uniform rule, but that
issue could be considered somewhat separately from how to print the
properties we choose to display.

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



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: SLRU optimization - configurable buffer pool and partitioning the SLRU lock
Next
From: Jelte Fennema-Nio
Date:
Subject: Re: Add new protocol message to change GUCs for usage with future protocol-only GUCs