From 031f588fbd38c71a6012054a87159ba695bb007a Mon Sep 17 00:00:00 2001 From: taojinlong Date: Sat, 22 Jul 2023 23:47:52 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=88=A4=E6=96=ADoracle=20timestemp?= =?UTF-8?q?=E7=B1=BB=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/io/dataease/provider/datasource/JdbcProvider.java | 2 +- .../io/dataease/provider/query/oracle/OracleQueryProvider.java | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/backend/src/main/java/io/dataease/provider/datasource/JdbcProvider.java b/backend/src/main/java/io/dataease/provider/datasource/JdbcProvider.java index fe9e1b457a..2b22a69d51 100644 --- a/backend/src/main/java/io/dataease/provider/datasource/JdbcProvider.java +++ b/backend/src/main/java/io/dataease/provider/datasource/JdbcProvider.java @@ -796,7 +796,7 @@ public class JdbcProvider extends DefaultJdbcProvider { break; case sqlServer: SqlServerConfiguration sqlServerConfiguration = new Gson().fromJson(datasource.getConfiguration(), SqlServerConfiguration.class); - if(!sqlServerConfiguration.getDataBase().matches("^[0-9a-zA-Z_.-]{1,}$")){ + if(!sqlServerConfiguration.getDataBase().matches("^[0-9a-zA-Z_.-\u4E00-\u9FA5\u8FBD-\u9FBB\uFA0E-\uFA29]{1,}$")){ throw new Exception("Invalid database name"); } break; diff --git a/backend/src/main/java/io/dataease/provider/query/oracle/OracleQueryProvider.java b/backend/src/main/java/io/dataease/provider/query/oracle/OracleQueryProvider.java index 1a9c0e078e..d0ae17c00d 100644 --- a/backend/src/main/java/io/dataease/provider/query/oracle/OracleQueryProvider.java +++ b/backend/src/main/java/io/dataease/provider/query/oracle/OracleQueryProvider.java @@ -60,6 +60,7 @@ public class OracleQueryProvider extends QueryProvider { @Override public Integer transFieldType(String field) { + field = field.split("()")[0]; switch (field) { case "CHAR": case "VARCHAR2":