Name: rmT116609 Date: 03/02/2004
A DESCRIPTION OF THE REQUEST :
There are specific get/set methods for the general types like BigDecimal: CallableStatement.setBigDecimal() and ResultSet.getBigDecimal(), but none for Integer!
JUSTIFICATION :
Instead of simple call getInteger()/setInteger() you have to write several lines of code:
Object o = rs.getObject(1);
if (o != null) {
obj.setIntegerValue(UtilClass.toInteger(o));
}
As setObject()/getObject() is often too slow and should be avoided and you can depend on the JDBC driver to always map the datatypes correctly, the setInteger()/getInteger() methods should strongly be implemented in Statements and ResultSet!
(Incident Review ID: 231329)
======================================================================
A DESCRIPTION OF THE REQUEST :
There are specific get/set methods for the general types like BigDecimal: CallableStatement.setBigDecimal() and ResultSet.getBigDecimal(), but none for Integer!
JUSTIFICATION :
Instead of simple call getInteger()/setInteger() you have to write several lines of code:
Object o = rs.getObject(1);
if (o != null) {
obj.setIntegerValue(UtilClass.toInteger(o));
}
As setObject()/getObject() is often too slow and should be avoided and you can depend on the JDBC driver to always map the datatypes correctly, the setInteger()/getInteger() methods should strongly be implemented in Statements and ResultSet!
(Incident Review ID: 231329)
======================================================================