File tree 1 file changed +3
-7
lines changed
dolphinscheduler-server/src/main/java/org/apache/dolphinscheduler/server/worker/task/sql
1 file changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -182,18 +182,14 @@ private SqlBinds getSqlAndSqlParamsMap(String sql) {
182
182
sqlParameters .getLocalParametersMap (),
183
183
CommandType .of (taskExecutionContext .getCmdTypeIfComplement ()),
184
184
taskExecutionContext .getScheduleTime ());
185
- if (MapUtils .isEmpty (paramsMap )){
186
- paramsMap =new HashMap <>();
185
+ if (paramsMap == null ) {
186
+ sqlBuilder .append (sql );
187
+ return new SqlBinds (sqlBuilder .toString (), sqlParamsMap );
187
188
}
188
189
if (MapUtils .isNotEmpty (taskExecutionContext .getParamsMap ())){
189
190
paramsMap .putAll (taskExecutionContext .getParamsMap ());
190
191
}
191
192
// spell SQL according to the final user-defined variable
192
- if (paramsMap .isEmpty ()){
193
- sqlBuilder .append (sql );
194
- return new SqlBinds (sqlBuilder .toString (), sqlParamsMap );
195
- }
196
-
197
193
if (StringUtils .isNotEmpty (sqlParameters .getTitle ())){
198
194
String title = ParameterUtils .convertParameterPlaceholders (sqlParameters .getTitle (),
199
195
ParamUtils .convert (paramsMap ));
You can’t perform that action at this time.
0 commit comments