diff --git a/Src/Asp.NetCore2/SqlSugar/Abstract/QueryableProvider/QueryableHelper.cs b/Src/Asp.NetCore2/SqlSugar/Abstract/QueryableProvider/QueryableHelper.cs index 9aee87a0a..c26efa98b 100644 --- a/Src/Asp.NetCore2/SqlSugar/Abstract/QueryableProvider/QueryableHelper.cs +++ b/Src/Asp.NetCore2/SqlSugar/Abstract/QueryableProvider/QueryableHelper.cs @@ -1269,6 +1269,7 @@ namespace SqlSugar if (attr != null && configId != attr.configId.ObjToString()) { var dbName = this.Context.Root.GetConnection(attr.configId).Ado.Connection.Database; + dbName = this.Context.Root.GetConnection(attr.configId).EntityMaintenance.GetEntityInfo(entity.Type).DbTableName; tableName = this.QueryBuilder.LambdaExpressions.DbMehtods.GetTableWithDataBase (this.QueryBuilder.Builder.GetTranslationColumnName(dbName), this.QueryBuilder.Builder.GetTranslationColumnName(tableName)); }