private void upgrade( DBHelper helper, CatalogVersion cv, CatalogSchemaVersion finalVersion, DBNative dbn, InformationCallback stdout) throws PEException { try { helper.executeQuery("update pe_version set state = 'upgrading'"); cv.upgrade(helper, stdout); if (dbn != null) upgradeInfoSchema(helper, dbn); helper.executeQuery("delete from pe_version"); helper.executeQuery(finalVersion.getInsertCommand()); } catch (SQLException sqle) { throw new PEException("Unable to upgrade to version " + cv.getSchemaVersion(), sqle); } }