Re: [HACKERS] psql: stdout or stderr? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [HACKERS] psql: stdout or stderr?
Date
Msg-id 7018.915121213@sss.pgh.pa.us
Whole thread Raw
In response to Re: [HACKERS] psql: stdout or stderr?  (Bruce Momjian <maillist@candle.pha.pa.us>)
Responses Re: [HACKERS] psql: stdout or stderr?  (Bruce Momjian <maillist@candle.pha.pa.us>)
List pgsql-hackers
Bruce Momjian <maillist@candle.pha.pa.us> writes:
>> Is that really what you want?  I would have thought errors would be sent
>> to stderr and that every thing else would go to stdout.

> Yes, this is new.  As I remember, some stuff is sent to stdout, and some
> to stderr, and there was some reason for that, though I can't remember
> what it was.  

I've always thought that psql is pretty inconsistent, arbitrary, and
unreasonable about what it chooses to write to stdout vs stderr.

However, if we rejigger what goes where, we will surely break a lot of
users' shell scripts, since those already expect particular output to go
to one or the other.  (We'd also break all the regression tests, but
at least those are within our power to fix.)

On the whole I'd vote against changing it --- a small improvement in
consistency is not worth the pain it will cause.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Andrey V Khavryutchenko
Date:
Subject: Re: [HACKERS] problems recovering 6.1 db
Next
From: "Thomas G. Lockhart"
Date:
Subject: Date/time fixes for HAVE_TM_ZONE platforms