Re: Consistent \d commands in psql - Mailing list pgsql-patches

From Brendan Jurd
Subject Re: Consistent \d commands in psql
Date
Msg-id 37ed240d0804020852t7eeb24y5d60b0ec1d8419ee@mail.gmail.com
Whole thread Raw
In response to Re: Consistent \d commands in psql  ("Greg Sabino Mullane" <greg@turnstep.com>)
List pgsql-patches
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 03/04/2008, Greg Sabino Mullane  wrote:
>  > \df Lists all user functions
>  > \df [pattern] Lists both system and user functions matching [pattern]
>  > \df * Lists all system and user functions
>
> I don't like this for two reasons: the items returned changes based on
>  the existence of args, rather than on the command itself, and more
>  importantly, this would make it inconsistent with the other backslash
>  commands.
>

To address your first complaint, I think it makes perfect sense to
behave differently based on whether an argument has been supplied.

The existence of a pattern tells you something about the user's
intention in issuing the command.  If they provide a pattern, they
probably want to /search/ for something.  If they don't provide a
pattern they probably want to get a /listing/ of some set.

Regards,
BJ
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: http://getfiregpg.org

iD8DBQFH86u15YBsbHkuyV0RAmcMAKCy44zQaEcPA+QDpXr2+3vrSPucDwCgg3FG
8cq7P2DvI/ogqrHwM9Zpzx0=
=IEvi
-----END PGP SIGNATURE-----

pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: Consistent \d commands in psql
Next
From: Chris Marcellino
Date:
Subject: Re: [HACKERS] POSIX shared memory support