public Integer createProjectRevision(Integer projectVerId, String refNum) throws SQLException { Connection dbConnection = null; CallableStatement stmt = null; ResultSet rs = null; try { dbConnection = this.getConnection(); String sql = "{ call AR_P_CREATE_CR_PROJ_REVISION(?, ?, ?) }"; stmt = dbConnection.prepareCall(sql); stmt.setInt("i_project_ver_id", projectVerId.intValue()); stmt.setString("i_project_ref_num", refNum); stmt.registerOutParameter("o_project_ver_id", Types.INTEGER); stmt.execute(); int projRevisionId = stmt.getInt("o_project_ver_id"); return new Integer(projRevisionId); } catch (SQLException e) { // e.printStackTrace(); return null; } finally { if(rs != null) rs.close(); if(stmt != null) stmt.close(); if(dbConnection != null) dbConnection.close(); rs = null; stmt = null; dbConnection = null; } }