Re: [Patch] New psql prompt substitution %r (m = master, r = replica)

Поиск
Список
Период
Сортировка
От Jim Nasby
Тема Re: [Patch] New psql prompt substitution %r (m = master, r = replica)
Дата
Msg-id d76d2619-6fc1-3f06-b945-fc053fdf2012@BlueTreble.com
обсуждение исходный текст
Ответ на Re: [Patch] New psql prompt substitution %r (m = master, r = replica)  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Список pgsql-hackers
On 8/18/16 10:05 AM, Alvaro Herrera wrote:
> Bash has PROMPT_COMMAND, which is executed prior to issuing each prompt.
> What about introducing such a feature into psql?  Then the \gset command
> you had in your first post could be used to set the variable correctly
> just before each prompt.

As someone that has the backend PID in his prompt... +1. Or 
alternatively, a command that is just run when the connection changes 
instead of every command...
-- 
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Experts in Analytics, Data Architecture and PostgreSQL
Data in Trouble? Get it in Treble! http://BlueTreble.com
855-TREBLE2 (855-873-2532)   mobile: 512-569-9461



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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: Bug in to_timestamp().
Следующее
От: Stefan Kaltenbrunner
Дата:
Сообщение: Re: WIP: About CMake v2