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.


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

Reply via email to