jdbc excpetions in pg - Mailing list pgsql-jdbc

From Thomas Finneid
Subject jdbc excpetions in pg
Date
Msg-id 2855.89.8.146.200.1244042913.squirrel@fcon.no
Whole thread Raw
Responses Re: jdbc excpetions in pg
List pgsql-jdbc
Hi

I was looking at the documentation for the pg jdbc driver and it seems to
me that the driver throws SQLExceptions only, or mostly. I.e. the driver
does not create any subclasses of the SQLException class. Is this correct?

If so, what is the suggested method for classifying the errors to more
detail than SQLException? I was hoping to make my code more robust by
dealing with the errors more appropriately.

regards

thomas


pgsql-jdbc by date:

Previous
From: Tom Lane
Date:
Subject: Re: [Patch] Binary Transfer v12
Next
From: user2037@ymail.com
Date:
Subject: Strings with null characters produce exceptions when selected or inserted. Attempts to select messages with null bytes produces "ERROR: insufficient data left in message". And inserting produces "ERROR: invalid byte sequence for encoding \"UTF8\": 0x00". Since a null character is a valid UTF code point why is it rejected by the JDBC driver? The attached test can work with Mysql and their JDBC driver.