slightly OT - stderr question

Richard Foley Richard.Foley at
Sun Nov 30 10:22:38 GMT 2008

Hi all,

I've come across this (bash) commandline program, in the course of some recent 
work, to which I'm objecting on two grounds:

1. It calls a java (!) program to connect to the db.

2. It returns STDERR from the db call on STDOUT.

My question is this: is this fair programming practice or is this a bag of 
shit?  My feeling is that it's the latter because if I write a perl wrapper 
around a database interface I would expect to have to capture, or at least 
redirect, STDERR such that errors from the database, for instance, would come 
out on STDERR as I would expect, whether wrapped in further error message 
handling or not.  The current code takes whatever output it recieves as 
feedback from the db call, ok messages and errors of all types, and simply 
pumps them all out onto STDOUT.  This, as you can imagine, is very 
frustrating when trying to seperate the 'wheat from the chaff', via a 
redirect at the commandline level for instance.  Am I being more than usually 
unreasonably pedantic here?

Richard Foley
Ciao - shorter than aufwiedersehen

ps. I realise this is slightly OT, for which I apologise, but I felt the group 
would at least have something to say about it :-)

More information about the mailing list