Re: postgres via shell scripts

Поиск
Список
Период
Сортировка
От bmccoy@chapelperilous.net
Тема Re: postgres via shell scripts
Дата
Msg-id Pine.LNX.4.10.10010061113260.5786-100000@chapelperilous.net
обсуждение исходный текст
Ответ на postgres via shell scripts  (Mike Sears <msears@vianet.ca>)
Ответы Re: postgres via shell scripts  (Jim Mercer <jim@reptiles.org>)
Список pgsql-general
On Fri, 6 Oct 2000, Mike Sears wrote:

> Is there away to access a postgres database using a shell script, like bash
> or korn?

You can use

psql -c <query>

or

psql -f <filename>

to do command-line stuff inside of a script.  But then you have to figure
out how to parse the result.  You're probably better off going the next
step and using Perl.

Brett W. McCoy
                                              http://www.chapelperilous.net
---------------------------------------------------------------------------
Imagination is more important than knowledge.
        -- Albert Einstein



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

Предыдущее
От: Mike Sears
Дата:
Сообщение: postgres via shell scripts
Следующее
От: Jim Mercer
Дата:
Сообщение: Re: postgres via shell scripts