// perform a query without records returned public boolean executeUpdate(String sql) { try { stmt = con.createStatement(); stmt.executeUpdate(sql); return true; } catch(SQLException e) { System.out.print("Update:"+e.getMessage()); return false; } }
// return the num of columns public int getColumns() { int columns = 0; try { this.resultsMeta = this.rs.getMetaData(); columns = this.resultsMeta.getColumnCount(); } catch (SQLException e) {} return columns; }
// return the num of rows public int getRows() { return this.rows; }