public inbox for [email protected]
help / color / mirror / Atom feedFrom: Tom Lane <[email protected]>
To: Robert Haas <[email protected]>
Cc: David G. Johnston <[email protected]>
Cc: Pavel Luzanov <[email protected]>
Cc: David Zhang <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: psql: Add role's membership options to the \du+ command
Date: Tue, 04 Apr 2023 13:12:33 -0400
Message-ID: <[email protected]> (raw)
In-Reply-To: <CA+TgmoatW6D_iyyCqbKcjS6MQt-fBTWzmynruk+x1B8oz22kog@mail.gmail.com>
References: <[email protected]>
<[email protected]>
<CAKFQuwbmAFfDw9ScCiOxK4UGf8Z8ny1nDgAn41gOJCeJ76QC4Q@mail.gmail.com>
<[email protected]>
<[email protected]>
<CAKFQuwYZ3S_A1ZKdnmOv-LueO1683UZf7AocNFTDjwEMLVfMOA@mail.gmail.com>
<[email protected]>
<CAKFQuwbkywHVFPL6TrJiHFd0KgEvdH0LZTSFxAdK4wzP-u8m-A@mail.gmail.com>
<[email protected]>
<CAKFQuwY9DtC8B-eCpHe39yK+y9LardAyaEz0ccVa_pQ+xBgr2Q@mail.gmail.com>
<[email protected]>
<CAKFQuwb6u62n=eq2ZXq6mbVTpqWR2bz_QhmLjWrQ89Kcoi5x+g@mail.gmail.com>
<CAKFQuwZTK7z=+rJkgbaZE=4H6FPxBJhbXBvKuR7e_vUXbPQEZw@mail.gmail.com>
<[email protected]>
<[email protected]>
<[email protected]>
<CAKFQuwZeayTSQSVBFRAohND2or! [email protected]>
<[email protected]>
<CA+TgmoatW6D_iyyCqbKcjS6MQt-fBTWzmynruk+x1B8oz22kog@mail.gmail.com>
Robert Haas <[email protected]> writes:
> I'm not sure what the right thing to do is here. It's a problem to
> have new information in the catalogs that you can't view via
> \d<whatever>. But displaying that information as a string of
> characters that will be gibberish to anyone but an expert doesn't
> necessarily seem like it really solves the problem. However, if we
> spell out the words, then it gets bulky. But maybe bulky is better
> than incomprehensible.
The existing precedent in \du definitely leans towards "bulky":
regression=# \du
List of roles
Role name | Attributes | Member of
-----------+------------------------------------------------------------+-----------
alice | Cannot login | {bob}
bob | Cannot login | {}
postgres | Superuser, Create role, Create DB, Replication, Bypass RLS | {}
It seems pretty inconsistent to me to treat the role attributes this
way and then economize in the adjacent column.
Another advantage to spelling out the SQL keywords is that it removes
the question of whether we should translate them.
I wonder if, while we're here, we should apply the idea of
joining-with-newlines-not-commas to the attributes column too.
That's another source of inconsistency in the proposed display.
regards, tom lane
view thread (29+ messages) latest in thread
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
Subject: Re: psql: Add role's membership options to the \du+ command
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox