public void deleteDepartment(int deptId) { PreparedStatement stat = null; try { String sql = "DELETE FROM Dept WHERE dept_id=" + deptId; stat = getAm().getDBTransaction().createPreparedStatement(sql, 1); stat.executeUpdate(); } catch (Exception e) { e.printStackTrace(); } finally { if(stat != null) try { stat.close(); } catch(Exception e) { } } return null; }