Re: [PATCHES] Friendly help for psql - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [PATCHES] Friendly help for psql
Date
Msg-id 6444.1201551659@sss.pgh.pa.us
Whole thread Raw
In response to Re: [PATCHES] Friendly help for psql  (Bruce Momjian <bruce@momjian.us>)
List pgsql-hackers
Bruce Momjian <bruce@momjian.us> writes:
> Alvaro Herrera wrote:
>> To avoid the usage of unadorned "help" (which I don't think is going to
>> ever cause conflicts with a SQL command but perhaps it's better to be
>> prepared), one idea would be to respond with "please execute \help
>> instead", and then \help would emit the verbose output.  Perhaps
>> eventually we could adorn it with "\help category", etc.

> Uh, imagine:

>     test=> SELECT * from pg_class
>     test-> help

You didn't read the patch: it would recognize "help" only when the input
buffer is empty.  The only thing it's assuming is that no SQL command
will ever *begin* with the word "help".
        regards, tom lane


pgsql-hackers by date:

Previous
From: "Greg Sabino Mullane"
Date:
Subject: Re: [GENERAL] SHA1 on postgres 8.3
Next
From: Tom Lane
Date:
Subject: Re: Strange locking choices in pg_shdepend.c