From c85195fcb17cde90b34132ab3690d6a012d3aeab Mon Sep 17 00:00:00 2001 From: taojinlong Date: Fri, 10 Jan 2025 16:00:56 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E3=80=90=E6=95=B0=E6=8D=AE=E9=9B=86?= =?UTF-8?q?=E3=80=91oracle=E5=8E=86=E5=8F=B2=E6=95=B0=E6=8D=AE=E6=9F=A5?= =?UTF-8?q?=E7=9C=8B=E6=8F=90=E7=A4=BA=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/io/dataease/commons/utils/SqlparserUtils.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/core-backend/src/main/java/io/dataease/commons/utils/SqlparserUtils.java b/core/core-backend/src/main/java/io/dataease/commons/utils/SqlparserUtils.java index f1e497f3ac..c0be58252b 100644 --- a/core/core-backend/src/main/java/io/dataease/commons/utils/SqlparserUtils.java +++ b/core/core-backend/src/main/java/io/dataease/commons/utils/SqlparserUtils.java @@ -50,13 +50,14 @@ public class SqlparserUtils { private final List> sysParams = new ArrayList<>(); public String handleVariableDefaultValue(String sql, String sqlVariableDetails, boolean isEdit, boolean isFromDataSet, List parameters, boolean isCross, Map dsMap, PluginManageApi pluginManage, UserFormVO userEntity) { + DatasourceSchemaDTO ds = dsMap.entrySet().iterator().next().getValue(); if (StringUtils.isEmpty(sql)) { DEException.throwException(Translator.get("i18n_sql_not_empty")); } this.userEntity = userEntity; try { this.removeSysParams = true; - removeVariables(sql, ""); + removeVariables(sql, ds.getType()); } catch (Exception e) { DEException.throwException(e); } @@ -103,7 +104,6 @@ public class SqlparserUtils { } try { - DatasourceSchemaDTO ds = dsMap.entrySet().iterator().next().getValue(); this.removeSysParams = false; sql = removeVariables(sql, ds.getType()); // replace keyword '`'