Skip to content

Commit

Permalink
0002032: Resolve table name in create trigger statement with default …
Browse files Browse the repository at this point in the history
…catalog and schema if source catalog and schema are not specified
  • Loading branch information
chenson42 committed Oct 29, 2014
1 parent f40eeef commit 9ffa8e5
Showing 1 changed file with 4 additions and 4 deletions.
Expand Up @@ -247,10 +247,10 @@ protected String getSourceTablePrefix(Table table) {
String prefix = (table.getSchema() != null ? table.getSchema() + "." : "");
prefix = (table.getCatalog() != null ? table.getCatalog() + "." : "") + prefix;
if (isBlank(prefix)) {
prefix = (symmetricDialect.getPlatform().getDefaultSchema() != null ? SymmetricUtils
prefix = (isNotBlank(symmetricDialect.getPlatform().getDefaultSchema()) ? SymmetricUtils
.quote(symmetricDialect, symmetricDialect.getPlatform().getDefaultSchema())
+ "." : "");
prefix = (symmetricDialect.getPlatform().getDefaultCatalog() != null ? SymmetricUtils
prefix = (isNotBlank(symmetricDialect.getPlatform().getDefaultCatalog()) ? SymmetricUtils
.quote(symmetricDialect, symmetricDialect.getPlatform().getDefaultCatalog())
+ "." : "") + prefix;
}
Expand All @@ -264,10 +264,10 @@ protected String getSourceTablePrefix(TriggerHistory triggerHistory) {
symmetricDialect, triggerHistory.getSourceCatalogName()) + "." : "")
+ prefix;
if (isBlank(prefix)) {
prefix = (symmetricDialect.getPlatform().getDefaultSchema() != null ? SymmetricUtils
prefix = (isNotBlank(symmetricDialect.getPlatform().getDefaultSchema()) ? SymmetricUtils
.quote(symmetricDialect, symmetricDialect.getPlatform().getDefaultSchema())
+ "." : "");
prefix = (symmetricDialect.getPlatform().getDefaultCatalog() != null ? SymmetricUtils
prefix = (isNotBlank(symmetricDialect.getPlatform().getDefaultCatalog()) ? SymmetricUtils
.quote(symmetricDialect, symmetricDialect.getPlatform().getDefaultCatalog())
+ "." : "") + prefix;
}
Expand Down

0 comments on commit 9ffa8e5

Please sign in to comment.