HHH-8138 - Log SQLException in DatabaseTarget with cause of schema export CREATE statement failure

This commit is contained in:
Steve Ebersole 2013-04-04 07:51:18 -05:00
parent 2a96ed865d
commit 907a2750b6
1 changed files with 3 additions and 2 deletions

View File

@ -62,7 +62,8 @@ class DatabaseTarget implements GenerationTarget {
} }
catch (SQLException e) { catch (SQLException e) {
throw new PersistenceException( throw new PersistenceException(
"Unable to execute JPA schema generation create command [" + command + "]" "Unable to execute JPA schema generation create command [" + command + "]",
e
); );
} }
} }
@ -93,7 +94,7 @@ class DatabaseTarget implements GenerationTarget {
} }
catch (SQLException e) { catch (SQLException e) {
// Just log the error because drop commands are often unsuccessful because the tables do not yet exist... // Just log the error because drop commands are often unsuccessful because the tables do not yet exist...
log.warn( String.format( "Unable to execute JPA schema generation drop command [%s]", command ), e ); log.warnf( "Unable to execute JPA schema generation drop command [" + command + "]", e );
} }
} }
} }