Re: Problem running script - Mailing list pgsql-general

From Francisco Reyes
Subject Re: Problem running script
Date
Msg-id [email protected]
Whole thread Raw
In response to Re: Problem running script  ("Ian Lea" <[email protected]>)
List pgsql-general
On 9:50 am 07/30/08 "Ian Lea" <[email protected]> wrote:
> $ psql -whatever < test.sql > test.log

Also
psql -f <filename> > test.log
Almost the same as above..


> >  =>\i test.sql \o test

That would be wrong.
Say you had test.sql
select * from mytable;

You can change test.sql to:
\o test.log
select * from mytable;

Then you could do \i test.sql and accomplish what you are trying to do.

If your DB has passwords enable you may need to put the user/password combo
in .pgpass.


pgsql-general by date:

Previous
From: "Ian Lea"
Date:
Subject: Re: Problem running script
Next
From: "Francisco Reyes"
Date:
Subject: Re: Connecting to an existing transaction state.