Re: [proposal] Add an option for returning SQLSTATE in psql error message

Peter Eisentraut <peter.eisentraut@2ndquadrant.com>

From: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
To: David Steele <david@pgmasters.net>, didier <did447@gmail.com>
Cc: Michael Paquier <michael@paquier.xyz>, Tom Lane <tgl@sss.pgh.pa.us>, Pavel Stěhule <pavel.stehule@gmail.com>, andrew@tao11.riddles.org.uk, PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2019-03-22T15:27:24Z
Lists: pgsql-hackers
On 2019-03-21 19:01, David Steele wrote:
> What do you think, Peter?  Is the extra test valuable or will it cause 
> unpredictable outputs as Tom and Michael predict?

Yes, I'm OK with that.

But now that I read the patch again, I'm not sure why this needs to
touch libpq.  The formatting of error messages in psql should be handled
in psql.

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


Commits

  1. Add a "SQLSTATE-only" error verbosity option to libpq and psql.