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

Re: Better psql tab-completion support for schemas and tables

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Greg Sabino Mullane <greg(at)turnstep(dot)com>
Cc: pgsql-patches(at)postgresql(dot)org
Subject: Re: Better psql tab-completion support for schemas and tables
Date: 2008-03-29 19:23:14
Message-ID: 19784.1206818594@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-patches
Greg Sabino Mullane <greg(at)turnstep(dot)com> writes:
> Full support for all schema and table name combinations when 
> getting a list of attributes. All of the following will now work:

> select * from information_schema.columns where <tab>
> select * from foo where <tab>
> select * from "user" where <tab>
> select * from "foo" where <tab>
> select * from "Uppercase".lower where <tab>
> select * from "gtsm.com"."foo.Bar" where <tab>
> select * from "GTSM.com".foo where <tab>

Applied with minor revisions.  I noticed while testing this that
although you fixed it for the case of the user having unnecessarily
quoted the preceding name, for example given a table foo,

	update "foo" set <tab>

it's still not bright about letting you complete such an entry in the
first place -- try

	update "f<tab>

That doesn't invalidate this patch, but there's still more work to do
on the completion queries.

			regards, tom lane

In response to

pgsql-patches by date

Next:From: Magnus HaganderDate: 2008-03-29 21:32:39
Subject: Re: create language ... if not exists
Previous:From: Heikki LinnakangasDate: 2008-03-29 19:00:42
Subject: Re: create language ... if not exists

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