Skip to content

Commit

Permalink
Fix unquote output_table in spark config
Browse files Browse the repository at this point in the history
  • Loading branch information
zixi0825 authored Dec 5, 2023
1 parent 81c8513 commit c44ec55
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ protected List<SourceConfig> getSourceConfigs() throws DataVinesException {

String outputTable = getOutputTable(metricInputParameter.get(DATABASE), metricInputParameter.get(SCHEMA), metricInputParameter.get(TABLE));
String tableAlias = getTableAlias(metricInputParameter.get(DATABASE), metricInputParameter.get(SCHEMA), metricInputParameter.get(TABLE), "1");
connectorParameterMap.put(OUTPUT_TABLE, outputTable);
connectorParameterMap.put(OUTPUT_TABLE, QuoteIdentifier.quote(outputTable));
connectorParameterMap.put(DRIVER, connectorFactory.getDialect().getDriver());

metricInputParameter.put(TABLE, QuoteIdentifier.quote(outputTable));
Expand Down Expand Up @@ -146,7 +146,7 @@ protected List<SourceConfig> getSourceConfigs() throws DataVinesException {
String tableAlias2 = getTableAlias(metricInputParameter.get(DATABASE2),
metricInputParameter.get(SCHEMA2),
metricInputParameter.get(TABLE2) ,"2");
connectorParameterMap.put(OUTPUT_TABLE, outputTable);
connectorParameterMap.put(OUTPUT_TABLE, QuoteIdentifier.quote(outputTable));
connectorParameterMap.put(DRIVER, connectorFactory.getDialect().getDriver());
metricInputParameter.put(TABLE2, QuoteIdentifier.quote(outputTable));
metricInputParameter.put(TABLE2_ALIAS, QuoteIdentifier.quote(tableAlias2));
Expand Down Expand Up @@ -248,6 +248,6 @@ public String getTableAlias(String database, String schema, String table, String
table = database + "_" + table;
}

return table+ "_" + order;
return table + "_" + order;
}
}

0 comments on commit c44ec55

Please sign in to comment.