mirror of
https://github.com/dataease/dataease.git
synced 2025-02-25 20:42:55 +08:00
fix: 校验数据库名称
This commit is contained in:
parent
6c45cd0567
commit
387571f9b2
@ -808,7 +808,7 @@ public class JdbcProvider extends DefaultJdbcProvider {
|
|||||||
break;
|
break;
|
||||||
case oracle:
|
case oracle:
|
||||||
OracleConfiguration oracleConfiguration = new Gson().fromJson(datasource.getConfiguration(), OracleConfiguration.class);
|
OracleConfiguration oracleConfiguration = new Gson().fromJson(datasource.getConfiguration(), OracleConfiguration.class);
|
||||||
if(!oracleConfiguration.getDataBase().matches("^[0-9a-zA-Z_]{1,}$")){
|
if(!oracleConfiguration.getDataBase().matches("^[0-9a-zA-Z_]{1,}$") && !oracleConfiguration.getConnectionType().equalsIgnoreCase("serviceName")){
|
||||||
throw new Exception("Invalid database name");
|
throw new Exception("Invalid database name");
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user