createObject(tableDefinition); createObject(tableDefinition); createObject(definition); } else { try { createObject(definition);
createObject(tableDefinition); createObject(tableDefinition); createObject(definition); } else { try { createObject(definition);
createObject(definition); } catch (DatabaseException exception) { createObject(definition);
if (!table.getName().equals(sequenceTableName)) { try { schemaManager.createObject(table); session.getSessionLog().log(SessionLog.FINEST, "default_tables_created", table.getFullName()); } catch (DatabaseException ex) {
missingTables.add(table); try { schemaManager.createObject(table); session.getSessionLog().log(SessionLog.FINEST, SessionLog.DDL, "default_tables_created", table.getFullName()); } catch (DatabaseException ex) {
missingTables.add(table); try { schemaManager.createObject(table); session.getSessionLog().log(SessionLog.FINEST, SessionLog.DDL, "default_tables_created", table.getFullName()); } catch (DatabaseException ex) {
schemaManager.createObject(table); session.getSessionLog().log(SessionLog.FINEST, SessionLog.DDL, "default_tables_created", table.getFullName()); } catch (DatabaseException exception) {
schemaManager.createObject(table); session.getSessionLog().log(SessionLog.FINEST, SessionLog.DDL, "default_tables_created", table.getFullName()); } catch (DatabaseException exception) {
/** * Use the definition object to drop and recreate the schema entity on the database. * This is used for dropping tables, views, procedures ... etc ... * This handles and ignore any database error while droping incase the object did not previously exist. */ public void replaceObject(DatabaseObjectDefinition databaseDefinition) throws EclipseLinkException { // PERF: Allow a special "fast" flag to be set on the session causes a delete from the table instead of a replace. boolean fast = FAST_TABLE_CREATOR; if (fast && (databaseDefinition instanceof TableDefinition)) { session.executeNonSelectingSQL("DELETE FROM " + databaseDefinition.getName()); } else { // CR 3870467, do not log stack boolean shouldLogExceptionStackTrace = getSession().getSessionLog().shouldLogExceptionStackTrace(); if (shouldLogExceptionStackTrace) { getSession().getSessionLog().setShouldLogExceptionStackTrace(false); } try { dropObject(databaseDefinition); } catch (DatabaseException exception) { // Ignore error } finally { if (shouldLogExceptionStackTrace) { getSession().getSessionLog().setShouldLogExceptionStackTrace(true); } } createObject(databaseDefinition); } }
/** * Use the definition object to drop and recreate the schema entity on the database. * This is used for dropping tables, views, procedures ... etc ... * This handles and ignore any database error while dropping in case the object did not previously exist. */ public void replaceObject(DatabaseObjectDefinition databaseDefinition) throws EclipseLinkException { // PERF: Allow a special "fast" flag to be set on the session causes a delete from the table instead of a replace. boolean fast = FAST_TABLE_CREATOR; if (fast && (databaseDefinition instanceof TableDefinition)) { session.executeNonSelectingSQL("DELETE FROM " + databaseDefinition.getName()); } else if (fast && (databaseDefinition instanceof StoredProcedureDefinition)) { // do nothing } else { // CR 3870467, do not log stack boolean shouldLogExceptionStackTrace = getSession().getSessionLog().shouldLogExceptionStackTrace(); if (shouldLogExceptionStackTrace) { getSession().getSessionLog().setShouldLogExceptionStackTrace(false); } try { dropObject(databaseDefinition); } catch (DatabaseException exception) { // Ignore error } finally { if (shouldLogExceptionStackTrace) { getSession().getSessionLog().setShouldLogExceptionStackTrace(true); } } createObject(databaseDefinition); } }
createObject(databaseDefinition);