Re: Redirect ERROR, FATAL and other messages

From: hubert depesz lubaczewski <depesz(at)depesz(dot)com>
To: pittgs <gabriela(dot)pittari(at)triagnosys(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Redirect ERROR, FATAL and other messages
Date: 2012-01-18 16:06:22
Message-ID: 20120118160622.GA4191@depesz.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Jan 18, 2012 at 03:20:05AM -0800, pittgs wrote:
> with "> logfile"
> Can somebody give me a hint to solve my issue?

errors are written not to stdout (which is redirected with >), but to
stderr.
which means, that you can redirect them, as with any other program, with
2>, like:

psql ... > logfile 2>&1

depesz

--
The best thing about modern society is how easy it is to avoid contact with it.
http://depesz.com/

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Antonio Franzoso 2012-01-18 16:33:47 Full text search - How to build a filtering dictionary
Previous Message Jerry Sievers 2012-01-18 15:46:51 Re: Redirect ERROR, FATAL and other messages