Backup manager bug

Error if no database. Fixed.
This commit is contained in:
Douglas Gillespie 2022-08-16 09:39:40 +01:00
parent f3ae5c9c4a
commit f640d86e9c

View File

@ -59,13 +59,15 @@ public class DatabaseCatalog extends BackupCatalog {
actionMap.put(action, ++ind);
}
makeTableDefinition();
dbControlUnit = DBControlUnit.findDatabaseControl();
pamConnection = dbControlUnit.getConnection();
DBProcess dbProcess = dbControlUnit.getDbProcess();
boolean tableOk = dbProcess.checkTable(fullTableDef);
if (tableOk == false) {
System.err.println("Error checking backup table " + fullTableDef.getTableName());
if (dbControlUnit != null) {
pamConnection = dbControlUnit.getConnection();
DBProcess dbProcess = dbControlUnit.getDbProcess();
boolean tableOk = dbProcess.checkTable(fullTableDef);
if (tableOk == false) {
System.err.println("Error checking backup table " + fullTableDef.getTableName());
}
}
}