psql commands for SQL/MED

Started by Peter Eisentrautabout 17 years ago9 messages
#1Peter Eisentraut
peter_e@gmx.net

The current proposed patch allocates the following psql \d commands:

\dw show foreign-data wrappers
\dr show foreign servers
\dm show user mappings

One might object that this allocates valuable letters for infrequently
used functionality.

In an idle second I thought, how about F for "foreign", but of course
\dF* is already used for full-text search. We could overload the F, but
it might be weird.

Other ideas?

#2Dimitri Fontaine
dfontaine@hi-media.com
In reply to: Peter Eisentraut (#1)
Re: psql commands for SQL/MED

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

Le 12 déc. 08 à 12:58, Peter Eisentraut a écrit :

The current proposed patch allocates the following psql \d commands:

[...]

In an idle second I thought, how about F for "foreign", but of
course \dF* is already used for full-text search. We could overload
the F, but it might be weird.

Other ideas?

What about \dM prefix, M standing for MED? It seems free in my 8.3
psql here.

Regards,
- --
dim

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Darwin)

iEYEARECAAYFAklCWOkACgkQlBXRlnbh1bkaWgCaA2Y02028n/+3BYPImJTEKJq8
ozgAn2v/XC+uSZy3imKCLW/tFt9Ohrik
=1ttA
-----END PGP SIGNATURE-----

#3Alvaro Herrera
alvherre@commandprompt.com
In reply to: Dimitri Fontaine (#2)
Re: psql commands for SQL/MED

Dimitri Fontaine wrote:

Le 12 d�c. 08 � 12:58, Peter Eisentraut a �crit :

In an idle second I thought, how about F for "foreign", but of course
\dF* is already used for full-text search. We could overload the F,
but it might be weird.

Other ideas?

What about \dM prefix, M standing for MED? It seems free in my 8.3 psql
here.

So \dMf for foreign servers, \dMu for user mappings, etc? That seems good.

--
Alvaro Herrera http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

#4Martin Pihlak
martin.pihlak@gmail.com
In reply to: Alvaro Herrera (#3)
Re: psql commands for SQL/MED

Alvaro Herrera wrote:

What about \dM prefix, M standing for MED? It seems free in my 8.3 psql
here.

So \dMf for foreign servers, \dMu for user mappings, etc? That seems good.

I find the mixed case commands somewhat inconvinient -- too easy to make
typing mistakes, also slow to enter. If we can afford it, I would suggest
\dmw, \dms and \dmu (wrappers, servers and user mappings).

regards,
Martin

#5Tom Lane
tgl@sss.pgh.pa.us
In reply to: Alvaro Herrera (#3)
Re: psql commands for SQL/MED

Alvaro Herrera <alvherre@commandprompt.com> writes:

Dimitri Fontaine wrote:

What about \dM prefix, M standing for MED? It seems free in my 8.3 psql
here.

So \dMf for foreign servers, \dMu for user mappings, etc? That seems good.

I'd suggest "e" for external. "M" for "management" is a pretty useless
mnemonic --- what's being managed?

regards, tom lane

#6David Fetter
david@fetter.org
In reply to: Tom Lane (#5)
Re: psql commands for SQL/MED

On Fri, Dec 12, 2008 at 08:24:36AM -0500, Tom Lane wrote:

Alvaro Herrera <alvherre@commandprompt.com> writes:

Dimitri Fontaine wrote:

What about \dM prefix, M standing for MED? It seems free in my
8.3 psql here.

So \dMf for foreign servers, \dMu for user mappings, etc? That
seems good.

I'd suggest "e" for external. "M" for "management" is a pretty
useless mnemonic --- what's being managed?

\def, \deu, etc. sound great :)

Cheers,
David.
--
David Fetter <david@fetter.org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david.fetter@gmail.com

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate

#7Alvaro Herrera
alvherre@commandprompt.com
In reply to: David Fetter (#6)
Re: psql commands for SQL/MED

David Fetter wrote:

On Fri, Dec 12, 2008 at 08:24:36AM -0500, Tom Lane wrote:

I'd suggest "e" for external. "M" for "management" is a pretty
useless mnemonic --- what's being managed?

\def, \deu, etc. sound great :)

\dew show foreign-data wrappers
\des show foreign servers
\deu show user mappings

--
Alvaro Herrera http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

#8Tom Lane
tgl@sss.pgh.pa.us
In reply to: Alvaro Herrera (#7)
Re: psql commands for SQL/MED

Alvaro Herrera <alvherre@commandprompt.com> writes:

\dew show foreign-data wrappers
\des show foreign servers
\deu show user mappings

Right, but maybe use "external" rather than "foreign" in the help
so that people recognize what the mnemonic is.

regards, tom lane

#9Josh Berkus
josh@agliodbs.com
In reply to: Tom Lane (#8)
Re: psql commands for SQL/MED

Tom Lane wrote:

Alvaro Herrera <alvherre@commandprompt.com> writes:

\dew show foreign-data wrappers
\des show foreign servers
\deu show user mappings

I'd prefer "external" rather than foreign, because new users could
confuse the latter with "foreign keys".

--Josh