pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Lew <noone@lwsc.ehost-services.com>
To: pgsql-jdbc@postgresql.org
Subject: Re: SQLException.getErrorCode ?
Date: Mon, 03 May 2010 00:26:45 -0400
Message-ID: <hrlja3$dl7$1@news.albasani.net> (raw)
In-Reply-To: <r2u554f5f781005011717jbd45f64g4129c5871434702a@mail.gmail.com>
References: <p2m554f5f781005010911te9f69ab9v12f20c3f2139e359@mail.gmail.com>
	<alpine.BSO.2.00.1005011217130.13830@leary.csoft.net>
	<4BDC2BBD0200002500031157@gw.wicourts.gov>
	<alpine.BSO.2.00.1005011540250.28968@leary.csoft.net>
	<t2z554f5f781005011441r9d9cd8a0z3838fbd76275c026@mail.gmail.com>
	<r2u554f5f781005011717jbd45f64g4129c5871434702a@mail.gmail.com>

On 05/01/2010 08:17 PM, Maxime Lévesque wrote:
>
>   I was just thinking that putting the getSQLState string in the
> exception's toString
> message would go a long way in hinting the users that postgres [sic] does
> provide error codes.

Umm, the SQLException documentation is quite clear the 'getErrorCode()' 
returns only vendor-specific codes and that 'getSQLState()' returns the SQL 
state value.  Since the latter is standard and the former is not, that already 
"goes a long way [to] hinting ... that" PG provides SQL Standard codes. 
Nothing further is needed.
<http://java.sun.com/javase/6/docs/api/java/sql/SQLException.html;

It seems fair that there is a presumption of knowledge of the standard.

-- 
Lew



view thread (7+ messages)

Message-ID: <hrlja3$dl7$1@news.albasani.net>
Permalink:  ../hrlja3$dl7$1@news.albasani.net/
Also on:    postgresql.org/message-id/hrlja3$dl7$1@news.albasani.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: noone@lwsc.ehost-services.com
  Subject: Re: SQLException.getErrorCode ?
  In-Reply-To: <hrlja3$dl7$1@news.albasani.net>
  References: <p2m554f5f781005010911te9f69ab9v12f20c3f2139e359@mail.gmail.com> <alpine.BSO.2.00.1005011217130.13830@leary.csoft.net> <4BDC2BBD0200002500031157@gw.wicourts.gov> <alpine.BSO.2.00.1005011540250.28968@leary.csoft.net> <t2z554f5f781005011441r9d9cd8a0z3838fbd76275c026@mail.gmail.com> <r2u554f5f781005011717jbd45f64g4129c5871434702a@mail.gmail.com> <hrlja3$dl7$1@news.albasani.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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