Re: PATCH: psql tab completion for SELECT

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: PATCH: psql tab completion for SELECT
Дата
Msg-id 12114.1520262270@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: PATCH: psql tab completion for SELECT  ("David G. Johnston" <david.g.johnston@gmail.com>)
Список pgsql-hackers
"David G. Johnston" <david.g.johnston@gmail.com> writes:
> On Mon, Mar 5, 2018 at 7:41 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> What would be actually useful is to be able to tab-complete even in
>> the midst of a failed transaction block ... but savepoints as such
>> won't get us there, and I have no good ideas about what would.

> ​Why not have psql open two sessions to the backend, one with
> application_name 'psql_user' and one with application name "psql_​meta" (or
> some such) and have all these queries executed on the psql_meta connection?

If we did it like that, tab completion would fail to see the session's
temp tables, or objects created in the current open transaction.

People might bitch about using twice as many connections, too, although
likely you could finesse that by only opening the second connection if
tab completion actually happens (so that only interactive sessions have
one).  Still, the local-objects problem seems like a fatal objection.

            regards, tom lane


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] Lazy hash table for XidInMVCCSnapshot (helps Zipfian a bit)
Следующее
От: Tom Lane
Дата:
Сообщение: Re: get_actual_variable_range vs idx_scan/idx_tup_fetch, again