Re: pg_restore to log file - Mailing list pgsql-general

From Scott Mead
Subject Re: pg_restore to log file
Date
Msg-id AANLkTimGa_QRexV_fZQimynsfSViNipVEQgpHnWlwXHi@mail.gmail.com
Whole thread Raw
In response to Re: pg_restore to log file  (akp geek <akpgeek@gmail.com>)
Responses Re: pg_restore to log file  (akp geek <akpgeek@gmail.com>)
List pgsql-general

On Tue, May 18, 2010 at 12:11 PM, akp geek <akpgeek@gmail.com> wrote:
pg_restore -h 10.xx.xx.xxx  -d dbName  -n schemaName -v -U postgres  testDB_20100414.txt    -f outputifile


I got the following error "pg_restore: options -d/--dbname and -f/--file cannot be used together"

I think you would either capture stdout or stderr (I'm honestly not sure which is required)


  pg_restore -all options >output.txt 2>&1

--Scott 


Regards




On Tue, May 18, 2010 at 12:07 PM, Thom Brown <thombrown@gmail.com> wrote:
On 18 May 2010 17:03, akp geek <akpgeek@gmail.com> wrote:
> Hi All -
>                 Is there a way to direct the message generated during
> pg_restore to a log file?
> Regards
>

I think you can use "-f outputfile".

Regards

Thom


pgsql-general by date:

Previous
From: akp geek
Date:
Subject: Re: pg_restore to log file
Next
From: Thom Brown
Date:
Subject: Re: pg_restore to log file