pg.ddx.io pgsql-jdbc@postgresql.org mailing list archive
help / color / mirror / Atom feedSQL Error Code Anomaly
2+ messages / 2 participants
[nested] [flat]
* SQL Error Code Anomaly
@ 2012-07-10 09:36 Johann 'Myrkraverk' Oskarsson <johann@2ndquadrant.com>
2012-07-11 01:21 ` Re: SQL Error Code Anomaly dmp <danap@ttc-cmc.net>
0 siblings, 1 reply; 2+ messages in thread
From: Johann 'Myrkraverk' Oskarsson @ 2012-07-10 09:36 UTC (permalink / raw)
To: pgsql-jdbc
Hi,
During my work on the binary stream patch, I came across this:
The error code PSQLState.NUMERIC_CONSTANT_OUT_OF_RANGE = 42820 is not
defined in
http://www.postgresql.org/docs/9.1/interactive/errcodes-appendix.html
Is this a concern? Is there a list of error codes defined by the JDBC
driver somewhere? I did not see anything at first glance.
I did not come across 42820 in the SQL standard either. Only that 42xxx
is _syntax error or access rule violation_.
A simple shell one liner shows these error codes used by the JDBC driver
but not documented in Postgres:
0100E
07006
08S01
42820
42821
60000
99999
I have not investigated this further.
--
Johann Oskarsson http://www.2ndquadrant.com/ |[]
PostgreSQL Development, 24x7 Support, Training and Services --+--
|
Blog: http://my.opera.com/myrkraverk/blog/
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: SQL Error Code Anomaly
2012-07-10 09:36 SQL Error Code Anomaly Johann 'Myrkraverk' Oskarsson <johann@2ndquadrant.com>
@ 2012-07-11 01:21 ` dmp <danap@ttc-cmc.net>
0 siblings, 0 replies; 2+ messages in thread
From: dmp @ 2012-07-11 01:21 UTC (permalink / raw)
To: Johann 'Myrkraverk' Oskarsson <johann@2ndquadrant.com>; pgsql-jdbc
Johann 'Myrkraverk' Oskarsson wrote:
> Hi,
>
> During my work on the binary stream patch, I came across this:
>
> The error code PSQLState.NUMERIC_CONSTANT_OUT_OF_RANGE = 42820 is not
> defined in
>
> http://www.postgresql.org/docs/9.1/interactive/errcodes-appendix.html
>
> Is this a concern? Is there a list of error codes defined by the JDBC
> driver somewhere? I did not see anything at first glance.
>
> I did not come across 42820 in the SQL standard either. Only that 42xxx
> is _syntax error or access rule violation_.
> I have not investigated this further.
I do not know if this is much more help, but the PSQLState class has a
general comment for a list of states which NUMERIC_CONSTANT_OUT_OF_RANGE
is one:
/**
* The server sent us a response the driver was not prepared for and
* is either bizarre datastream corruption, a driver bug, or
* a protocol violation on the server's part.
*/
Upon a little futher digging this particular state is associated with the
two classes PGInterval & PGMoney. In PGInterval it is thrown on a Number
FormatException looks like if an invalid character is given for the interval.
In PGMoney likewise. Both of these occurs while setting the Value. Now my
code is a litle out of date so this might not be totally accurate.
danap.
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2012-07-11 01:21 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2012-07-10 09:36 SQL Error Code Anomaly Johann 'Myrkraverk' Oskarsson <johann@2ndquadrant.com>
2012-07-11 01:21 ` dmp <danap@ttc-cmc.net>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox