Code example for PreparedStatement

Methods: setBigDecimal

0
  public static void writeBigDecimal(BigDecimal val, int paramIdx,
      int sqlType, PreparedStatement s) throws SQLException {
    if (null == val) {
      s.setNull(paramIdx, sqlType);
    } else { 
      s.setBigDecimal(paramIdx, val);
    } 
  } 
 
  public static void writeBlobRef(BlobRef val, int paramIdx,
      int sqlType, PreparedStatement s) throws SQLException {
    // TODO: support this. 
    throw new RuntimeException("Unsupported: Cannot export BLOB data");
  } 
 
  public static void writeClobRef(ClobRef val, int paramIdx,
      int sqlType, PreparedStatement s) throws SQLException {
    // TODO: support this. 
    throw new RuntimeException("Unsupported: Cannot export CLOB data");
  } 
}