mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-07-31 15:56:25 +08:00
Optimize 金仓R3
This commit is contained in:
parent
e5931a38cc
commit
0086215f2e
@ -419,6 +419,15 @@ WHERE tgrelid = '" + tableName + "'::regclass");
|
||||
IsAutoCloseConnection = true,
|
||||
ConnectionString = connection
|
||||
});
|
||||
if (newDb.Ado.IsValidConnection() == false)
|
||||
{
|
||||
newDb = new SqlSugarClient(new ConnectionConfig()
|
||||
{
|
||||
DbType = this.Context.CurrentConnectionConfig.DbType,
|
||||
IsAutoCloseConnection = true,
|
||||
ConnectionString = this.Context.CurrentConnectionConfig.ConnectionString.Replace(oldDatabaseName, "TEST")
|
||||
});
|
||||
}
|
||||
if (!GetDataBaseList(newDb).Any(it => it.Equals(databaseName, StringComparison.CurrentCultureIgnoreCase)))
|
||||
{
|
||||
newDb.Ado.ExecuteCommand(string.Format(CreateDataBaseSql, this.SqlBuilder.SqlTranslationLeft+databaseName+this.SqlBuilder.SqlTranslationRight, databaseDirectory));
|
||||
|
Loading…
Reference in New Issue
Block a user