Re: Feature request: make cluster_name GUC useful for psql prompts

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: Feature request: make cluster_name GUC useful for psql prompts
Дата
Msg-id f88d13f5-51f0-8754-90a3-2728e6bb0f3f@2ndquadrant.com
обсуждение исходный текст
Ответ на Feature request: make cluster_name GUC useful for psql prompts  (Steve Crawford <scrawford@pinpointresearch.com>)
Ответы Re: Feature request: make cluster_name GUC useful for psql prompts  (Jerry Sievers <gsievers19@comcast.net>)
Список pgsql-hackers
On 5/5/16 9:21 PM, Steve Crawford wrote:
> Adding an escape sequence that references cluster_name would enable
> prompts to identify the cluster in a manner that is both consistent and
> distinct regardless of access path.

I think that would be a good idea.  You could probably design it so that 
any server parameter reported to the client can be put in a psql prompt.

> Potential issues/improvements:
>
> What should the escape-sequence display if cluster_name is not set or
> the cluster is a pre-9.5 version. %M? %m?
>
> In future server versions should there be a default for cluster_name if
> it is not set? If so, what should it be? Would the server canonical
> hostname + listen-port be reasonable?

Those are good questions.  I don't really like the proposed answers, 
because that could cause confusion in practical use.

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



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

Предыдущее
От: Alex Ignatov
Дата:
Сообщение: Re: Is pg_control file crashsafe?
Следующее
От: Dean Rasheed
Дата:
Сообщение: Re: psql :: support for \ev viewname and \sv viewname