Re: psql and output from \?

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: Ian Barwick <barwick(at)gmx(dot)net>, PostgreSQL Development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: psql and output from \?
Date: 2002-03-11 18:26:53
Message-ID: 200203111826.g2BIQr427796@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut wrote:
> Ian Barwick writes:
>
> > Appended is a list of relevant backslash commands, their current
> > description as produced by \?, the respective manpage description (or
> > first part thereof) and suggested replacment for the \? description.
> > Assumption is that square brackets - as used elsewhere within the
> > \? output and the manpage documentation - imply optional parameters.
>
> Nicely observed. Please send in a patch. Accurate documentation is
> important.

Done.

> Also, the part in the parentheses is ambiguous. Maybe "(without
> arguments: unset)".

I made it consistent with others, no parens.

fprintf(fout, _(" \\f [SEPARATOR] set field separator, or unset if none\n")

>
> > psql \? new:
> > \d [ RELATION ] describe relation (table, view, index or sequence)
>
> Comma before "or".

Already done.

>
> > psql \? new:
> > \e [ FILENAME ] edit the current query buffer or file with external editor
>
> Maybe drop the "current". (This was not introduced by you, but you might
> as well do it.)

I removed current in all \? cases when describing query buffer.

>
> Something that's also annoyed me for a while is that the PLACEHOLDER
> strings are inconsistent in whether they describe the data type or the
> semantics of the argument. I think the data type is ultimately more
> useful, as the semantics come from the documentation string by definition.
>
> So instead of \C TITLE maybe better \C STRING, and instead of \d TABLE use
> \d IDENTIFIER (or maybe NAME). The latter has two advantages: First
> you're not passing \d a table descriptor, if there was such a thing. And
> second, it informs the user that the SQL identifier quoting rules will
> apply to the argument. I guess FILENAME and DIRNAME are ok as "data
> types", but all the other stuff can go, I think.

I can understand a more formal indicator in the documentation, but for
\? it is really just quick help, and showing SEPARATOR rather than the more
generic STRING is clearer, I think.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2002-03-11 20:52:51 Re: Domain Support -- another round
Previous Message Bruce Momjian 2002-03-11 18:21:29 Re: psql and output from \?