Re: [PROPOSAL] Make PSQLVAR on \getenv opitional

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [PROPOSAL] Make PSQLVAR on \getenv opitional
Дата
Msg-id 1916648.1640721194@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [PROPOSAL] Make PSQLVAR on \getenv opitional  (Matheus Alcantara <msalcantara.dev@pm.me>)
Ответы Re: [PROPOSAL] Make PSQLVAR on \getenv opitional  (Matheus Alcantara <msalcantara.dev@pm.me>)
Re: [PROPOSAL] Make PSQLVAR on \getenv opitional  (Andrew Dunstan <andrew@dunslane.net>)
Список pgsql-hackers
Matheus Alcantara <msalcantara.dev@pm.me> writes:
>> it is not consistent with other \g* commands. Maybe a new statement \senv ? But what is the use case? You can just
press^z and inside shell write echo $xxx, and then fg 

> I think that the basic use case would be just for debugging, instead call \getenv and them \echo, we could just use
\getenv.I don't see any other advantages, It would just be to 
> write fewer commands. I think that ^z and then fg is a good alternative, since this behavior would be inconsistent.

You don't even need to do that much.  This works fine:

postgres=# \! echo $PATH

So I'm not convinced that we need another way to spell that.
(Admittedly, this probably doesn't work on Windows, but
I gather that environment variables are less interesting there.)

            regards, tom lane



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

Предыдущее
От: Adam Brusselback
Дата:
Сообщение: Re: Foreign key joins revisited
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: Foreign key joins revisited