Skip to content

Commit

Permalink
fix modify the display default value inner 1846
Browse files Browse the repository at this point in the history
fix  modify the display default value inner 1846
  • Loading branch information
ylinzhu authored Dec 23, 2022
2 parents 74e2023 + 4582d5b commit 59e8fce
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public DelayDetection(PhysicalDbInstance source) {
}

private void synSql() {
String[] str = {"dble", SystemConfig.getInstance().getInstanceName(), dbGroupConfig.getName()};
String[] str = {"dble", dbGroupConfig.getName(), SystemConfig.getInstance().getInstanceName()};
sourceName = Joiner.on("_").join(str);
String schema = dbGroupConfig.getDelayDatabase();
String tableName = ".u_delay ";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,17 @@ protected List<LinkedHashMap<String, String>> getRows() {
map.put(COLUMN_ACTIVE, Boolean.TRUE.toString());
return map;
}).collect(Collectors.toList());
tempRowList.forEach(this::defaultVal);
rowList.addAll(tempRowList);
return rowList;
}

private void defaultVal(LinkedHashMap<String, String> rows) {
//if the argument is null, then a string equal to "null"
String delayDatabase = rows.get(DELAY_DATABASE);
rows.put(DELAY_DATABASE, String.valueOf(delayDatabase));
}

@Override
public int insertRows(List<LinkedHashMap<String, String>> rows) {
//check rule
Expand Down

0 comments on commit 59e8fce

Please sign in to comment.