public int update(String sql) throws SQLException {
  Connection connection=null;
  PreparedStatement stmt=null;
  try {
    connection=source.getConnection();
    stmt=connection.prepareStatement(sql);
    return stmt.executeUpdate();
  }
  finally {
    SQLUtil.closeQuietly(stmt);
    SQLUtil.closeQuietly(connection);
  }
}

public int update ( String sql ) throws SQLException { Connection connection = null ; PreparedStatement stmt = null ; try { connection = source . getConnection ( ) ; stmt = connection . prepareStatement ( sql ) ; return stmt . executeUpdate ( ) ; } finally { SQLUtil . closeQuietly ( stmt ) ; SQLUtil . closeQuietly ( connection ) ; } }
perform sql update statement .
