On Wed, 25 Jan 2006, Chetan wrote:
Earlier in my code, whenever i was doing a resultSet.getString('some column
name'), the return value would be an empty string ('') in case the column in
the database was null. However, after using DBCP, similar statements return
The JDBC specification (e.g. JDBC 3.0, Chapter 14.2.3.3) states that for
database rows that contain NULL: "Column values that map to Java Object
types are returned as a Java null;"
Your implementation does not follow the JDBC specification, therefore it's
not possible to change the implementation easily.
Is there any way by which i could make the DBCP connection broker return an
empty string instead of a null so that i dont need to make changes in
numerous places in my application to handle the null pointer case ?
I strongly recommend you to follow the JDBC specification (better change
your implementation now than later). This will make it possible to
exchange the implementation as you like.
cu
Stefan Rufer
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]