public int updateDB(String sql) {
    int result = 0;
    try {
    	 stmt = conn.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE,ResultSet.CONCUR_READ_ONLY);
         result = stmt.executeUpdate(sql);;
      }catch (SQLException e) {
    	System.out.println(""+result);
    	System.err.println(e.getMessage());
      result = 0;
    }
    try {
      stmt.close();
    }catch (SQLException e) {
    	System.err.println(e.getMessage());
    }
    return result;
  }