yea with a typeHandler like this i cen get through the problem

public Object getResult(CallableStatement cs, int columnIndex)
                        throws SQLException {
                 Object s = cs.getString(columnIndex);
                if(cs.wasNull())
                    return Constants.EMPTY_STRING;
                else
                    return ((String)s).trim();
        }
        public Object getResult(ResultSet rs, int columnInt) throws 
SQLException {
                Object s = rs.getString(columnInt);
        if(rs.wasNull())
            return Constants.EMPTY_STRING;
        else
            return ((String)s).trim();
        }
        public Object getResult(ResultSet rs, String columnName) throws
SQLException {
                Object s = rs.getString(columnName);
        if(rs.wasNull())
            return Constants.EMPTY_STRING;
        else
            return ((String)s).trim();
        }
        
    public void setParameter(PreparedStatement ps, int i, Object parameter,
String jdbcType)
    throws SQLException
{       
    if (parameter!=null && !parameter.equals(Constants.EMPTY_STRING))
        ps.setString(i, (String)parameter);
    else 
        ps.setString(i, Constants.EMPTY_STRING);
}

Thanks guys

WDYS



Gilles Bayon wrote:
> 
> You can use a custom string  type handler.
> 
> -- 
> Cheers,
> Gilles
> 
> 

-- 
View this message in context: 
http://www.nabble.com/JDBC-Type-0-not-yet-supported-tp17688418p17690887.html
Sent from the iBATIS - User - Java mailing list archive at Nabble.com.

Reply via email to