mirror of
https://gitee.com/dolphinscheduler/DolphinScheduler.git
synced 2024-12-01 11:47:51 +08:00
parent
f7e89e4561
commit
4440b35c4e
@ -299,7 +299,11 @@ public class SqlTask extends AbstractTask {
|
||||
while (resultSet.next()) {
|
||||
JSONObject mapOfColValues = new JSONObject(true);
|
||||
for (int i = 1; i <= num; i++) {
|
||||
mapOfColValues.put(md.getColumnName(i), resultSet.getObject(i));
|
||||
if (StringUtils.isNotEmpty(md.getColumnLabel(i))) {
|
||||
mapOfColValues.put(md.getColumnLabel(i), resultSet.getObject(i));
|
||||
} else {
|
||||
mapOfColValues.put(md.getColumnName(i), resultSet.getObject(i));
|
||||
}
|
||||
}
|
||||
resultJSONArray.add(mapOfColValues);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user