Re: BUG #16868: Cannot find sqlstat error codes. - Mailing list pgsql-bugs

From David G. Johnston
Subject Re: BUG #16868: Cannot find sqlstat error codes.
Date
Msg-id CAKFQuwZKC56K_kR4z905wbDwhyZ9QwYXCXAuHguJq0UZOQ6eBg@mail.gmail.com
Whole thread Raw
In response to Re: BUG #16868: Cannot find sqlstat error codes.  (bipsy Nair <nbipin29@gmail.com>)
List pgsql-bugs
On Wed, Feb 17, 2021 at 4:55 PM bipsy Nair <nbipin29@gmail.com> wrote:

This is what leads me to think that it's potentially a problem in the RDS Postgres internals.


This is unlikely.  I suspect that since Boto is intended as an abstraction layer it simply doesn't care about trying to get verbose error details from PostgreSQL and so ignores the SQLSTATE error code.  Since the server doesn't put the error code into the error message, as it seems MySQL does by your examples, the code is simply unavailable without code changes to the client database driver.

Sure, PostgreSQL could add a server option to print the SQLSTATE error code as part of the error message.  But it doesn't, nor do I suspect that is likely to change.

The server provides the data; complain to the client software developer if they are not making it accessible to you in the way you need when you use their software.

David J.

pgsql-bugs by date:

Previous
From: bipsy Nair
Date:
Subject: Re: BUG #16868: Cannot find sqlstat error codes.
Next
From: Kasahara Tatsuhito
Date:
Subject: Re: BUG #16722: PG hanging on COPY when table has close to 2^32 toasts in the table.