Re: Slow tab completion w/ lots of tables

From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: "Stephen Frost" <sfrost(at)snowman(dot)net>, "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "Robert Haas" <robertmhaas(at)gmail(dot)com>, <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Slow tab completion w/ lots of tables
Date: 2012-08-21 18:04:53
Message-ID: 50338775020000250004999B@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:

> We'd still emit quote_ident output, which means that if you did
>
> select * from TE<TAB>
>
> it would change that to
>
> select * from "TEST
>
> (assuming you had say TEST1 and TEST2 so it couldn't complete
> further).

> if the word-so-far has a leading quote and no embedded quotes, we
> can clearly strip the leading quote and compare the rest directly
> to the name column. So that can be fast. The only cases that
> need be slow are names with embedded quotes, which surely isn't a
> case that too many people care about.
>
> In short, I think we might be able to make this fast, and more
> usable, just with hacking on psql's query generation rules.
> There's no need for server-side changes.

I like it. A lot. With our camel-case naming convention, it would
make life a lot easier.

-Kevin

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2012-08-21 18:07:10 Re: 9.2RC1 wraps this Thursday ...
Previous Message Tom Lane 2012-08-21 18:03:42 Re: Slow tab completion w/ lots of tables