Skip site navigation (1) Skip section navigation (2)

Re: [PATCHES] Friendly help for psql

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Peter Eisentraut <peter_e(at)gmx(dot)net>, Greg Sabino Mullane <greg(at)turnstep(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Re: [PATCHES] Friendly help for psql
Date: 2008-01-28 20:20:59
Message-ID: 6444.1201551659@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-patches
Bruce Momjian <bruce(at)momjian(dot)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

In response to

pgsql-hackers by date

Next:From: Tom LaneDate: 2008-01-28 20:29:20
Subject: Re: Strange locking choices in pg_shdepend.c
Previous:From: Greg Sabino MullaneDate: 2008-01-28 20:15:54
Subject: Re: [GENERAL] SHA1 on postgres 8.3

pgsql-patches by date

Next:From: Bruce MomjianDate: 2008-01-28 20:40:20
Subject: Re: Friendly help for psql
Previous:From: David FetterDate: 2008-01-28 20:08:00
Subject: Re: Auto-explain patch

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group