psql tab completion for SELECT

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Cc: hubert depesz lubaczewski <depesz(at)depesz(dot)com>
Subject: psql tab completion for SELECT
Date: 2012-02-09 20:49:39
Message-ID: 1328820579.11241.4.camel@vanquo.pezone.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

In his blog entry http://www.depesz.com/2011/07/08/wish-list-for-psql/
depesz described a simple way to do tab completion for SELECT in psql:

"""
Make tab-completion complete also function names – like: SELECT
pg_get<tab><tab> to see all functions that start with pg_get.

Make tab-completion work for columns in SELECT. I know that when writing
SELECT clause, psql doesn’t know which table it will deal with, but it
could search through all the columns in database.
"""

That seems pretty useful, and it's more or less a one-line change, as in
the attached patch.

Attachment Content-Type Size
psql-select-completion.patch text/x-patch 623 bytes

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Marti Raudsepp 2012-02-09 21:11:16 RFC: Making TRUNCATE more "MVCC-safe"
Previous Message Jay Levitt 2012-02-09 20:37:20 Re: Bugs/slowness inserting and indexing cubes