/** Check to see if a database has been upgraded to the required level in order to use a language feature. @param requiredMajorVersion Data Dictionary major version @param feature Non-null to throw an error, null to return the state of the version match. @return True if the database has been upgraded to the required level, false otherwise. */ public boolean checkVersion(int requiredMajorVersion, String feature) throws StandardException { if (requiredMajorVersion == DataDictionary.DD_VERSION_CURRENT) { requiredMajorVersion = softwareVersion.majorVersionNumber; } return dictionaryVersion.checkVersion(requiredMajorVersion, feature); }
/** * Construct a Version for the currently booting data dictionary. * The minor version is set by the subclass. * * @param bootingDictionary The booting dictionary that needs to be upgraded. */ DD_Version( DataDictionaryImpl bootingDictionary, int majorVersionNumber) { this.majorVersionNumber = majorVersionNumber; this.minorVersionNumber = getJBMSMinorVersionNumber(); this.bootingDictionary = bootingDictionary; }
/** * Stringify this Version. * * @return String representation of this Version. */ public String toString() { return DD_Version.majorToString(majorVersionNumber); }
if (Monitor.isFullUpgrade(startParams, dictionaryVersion.toString())) { performMajorUpgrade = true; } else { doFullUpgrade(tc, dictionaryVersion.majorVersionNumber,IdUtil.getUserAuthorizationId(userName)); applySafeChanges( tc, dictionaryVersion.majorVersionNumber, softUpgradeMajorVersion); handleMinorRevisionChange(tc, dictionaryVersion, softUpgradeRun);
/** * Drop a System catalog. * @param tc TransactionController * @param crf CatalogRowFactory for the catalog to drop. * @exception StandardException Standard Derby error policy. */ protected void dropSystemCatalog(TransactionController tc, CatalogRowFactory crf) throws StandardException { SchemaDescriptor sd = bootingDictionary.getSystemSchemaDescriptor(); TableDescriptor td = bootingDictionary.getTableDescriptor( crf.getCatalogName(), sd, tc); ConglomerateDescriptor[] cds = td.getConglomerateDescriptors(); for (int index = 0; index < cds.length; index++) { tc.dropConglomerate(cds[index].getConglomerateNumber()); } dropSystemCatalogDescription(tc,td); }
modifySysTableNullability(tc, DataDictionaryImpl.SYSSTATEMENTS_CATALOG_NUM); modifySysTableNullability(tc, DataDictionaryImpl.SYSVIEWS_CATALOG_NUM);
throws StandardException softwareVersion = new DD_Version(this, DataDictionary.DD_VERSION_DERBY_10_4);
if (Monitor.isFullUpgrade(startParams, dictionaryVersion.toString())) { performMajorUpgrade = true; } else { doFullUpgrade(tc, dictionaryVersion.majorVersionNumber,IdUtil.getUserAuthorizationId(userName)); applySafeChanges( tc, dictionaryVersion.majorVersionNumber, softUpgradeMajorVersion); handleMinorRevisionChange(tc, dictionaryVersion, softUpgradeRun);
/** * Drop a System catalog. * @param tc TransactionController * @param crf CatalogRowFactory for the catalog to drop. * @exception StandardException Standard Derby error policy. */ protected void dropSystemCatalog(TransactionController tc, CatalogRowFactory crf) throws StandardException { SchemaDescriptor sd = bootingDictionary.getSystemSchemaDescriptor(); TableDescriptor td = bootingDictionary.getTableDescriptor( crf.getCatalogName(), sd, tc); ConglomerateDescriptor[] cds = td.getConglomerateDescriptors(); for (int index = 0; index < cds.length; index++) { tc.dropConglomerate(cds[index].getConglomerateNumber()); } dropSystemCatalogDescription(tc,td); }
modifySysTableNullability(tc, DataDictionaryImpl.SYSSTATEMENTS_CATALOG_NUM); modifySysTableNullability(tc, DataDictionaryImpl.SYSVIEWS_CATALOG_NUM);
throws StandardException softwareVersion = new DD_Version(this, DataDictionary.DD_VERSION_DERBY_10_4);
if (Monitor.isFullUpgrade(startParams, dictionaryVersion.toString())) { performMajorUpgrade = true; } else { doFullUpgrade(tc, dictionaryVersion.majorVersionNumber,IdUtil.getUserAuthorizationId(userName)); applySafeChanges( tc, dictionaryVersion.majorVersionNumber, softUpgradeMajorVersion); handleMinorRevisionChange(tc, dictionaryVersion, softUpgradeRun);
/** * Stringify this Version. * * @return String representation of this Version. */ public String toString() { return DD_Version.majorToString(majorVersionNumber); }
/** Check to see if a database has been upgraded to the required level in order to use a language feature. @param requiredMajorVersion Data Dictionary major version @param feature Non-null to throw an error, null to return the state of the version match. @return True if the database has been upgraded to the required level, false otherwise. */ public boolean checkVersion(int requiredMajorVersion, String feature) throws StandardException { if (requiredMajorVersion == DataDictionary.DD_VERSION_CURRENT) { requiredMajorVersion = softwareVersion.majorVersionNumber; } return dictionaryVersion.checkVersion(requiredMajorVersion, feature); }
/** * Construct a Version for the currently booting data dictionary. * The minor version is set by the subclass. * * @param bootingDictionary The booting dictionary that needs to be upgraded. */ DD_Version( DataDictionaryImpl bootingDictionary, int majorVersionNumber) { this.majorVersionNumber = majorVersionNumber; this.minorVersionNumber = getJBMSMinorVersionNumber(); this.bootingDictionary = bootingDictionary; }
/** * Drop a System catalog. * @param tc TransactionController * @param crf CatalogRowFactory for the catalog to drop. * @exception StandardException Standard Derby error policy. */ protected void dropSystemCatalog(TransactionController tc, CatalogRowFactory crf) throws StandardException { SchemaDescriptor sd = bootingDictionary.getSystemSchemaDescriptor(); TableDescriptor td = bootingDictionary.getTableDescriptor( crf.getCatalogName(), sd, tc); ConglomerateDescriptor[] cds = td.getConglomerateDescriptors(); for (int index = 0; index < cds.length; index++) { tc.dropConglomerate(cds[index].getConglomerateNumber()); } dropSystemCatalogDescription(tc,td); }
modifySysTableNullability(tc, DataDictionaryImpl.SYSSTATEMENTS_CATALOG_NUM); modifySysTableNullability(tc, DataDictionaryImpl.SYSVIEWS_CATALOG_NUM);
throws StandardException softwareVersion = new DD_Version(this, DataDictionary.DD_VERSION_DERBY_10_4);
/** * Stringify this Version. * * @return String representation of this Version. */ public String toString() { return DD_Version.majorToString(majorVersionNumber); }
/** Check to see if a database has been upgraded to the required level in order to use a language feature. @param requiredMajorVersion Data Dictionary major version @param feature Non-null to throw an error, null to return the state of the version match. @return True if the database has been upgraded to the required level, false otherwise. */ public boolean checkVersion(int requiredMajorVersion, String feature) throws StandardException { if (requiredMajorVersion == DataDictionary.DD_VERSION_CURRENT) { requiredMajorVersion = softwareVersion.majorVersionNumber; } return dictionaryVersion.checkVersion(requiredMajorVersion, feature); }