diff --git a/Src/Asp.NetCore2/SqlSugar/Abstract/UpdateProvider/UpdateableProvider.cs b/Src/Asp.NetCore2/SqlSugar/Abstract/UpdateProvider/UpdateableProvider.cs index 51d9283dc..0f9fc7293 100644 --- a/Src/Asp.NetCore2/SqlSugar/Abstract/UpdateProvider/UpdateableProvider.cs +++ b/Src/Asp.NetCore2/SqlSugar/Abstract/UpdateProvider/UpdateableProvider.cs @@ -204,6 +204,16 @@ namespace SqlSugar result.updateableObj.UpdateBuilder.ShortName = joinExpress.Parameters.FirstOrDefault()?.Name; return result; } + public IUpdateable InnerJoin(Expression> joinExpress,string TableName) + { + UpdateableProvider result = new UpdateableProvider(); + result.updateableObj = this; + var querybale = this.Context.Queryable().LeftJoin(joinExpress); + result.updateableObj.UpdateBuilder.JoinInfos = querybale.QueryBuilder.JoinQueryInfos; + result.updateableObj.UpdateBuilder.ShortName = joinExpress.Parameters.FirstOrDefault()?.Name; + result.updateableObj.UpdateBuilder.TableName = TableName; + return result; + } public IUpdateable Clone() { this.Context.SugarActionType = SugarActionType.Update; diff --git a/Src/Asp.NetCore2/SqlSugar/Interface/IUpdateable.cs b/Src/Asp.NetCore2/SqlSugar/Interface/IUpdateable.cs index 47489c8cb..566ebd29e 100644 --- a/Src/Asp.NetCore2/SqlSugar/Interface/IUpdateable.cs +++ b/Src/Asp.NetCore2/SqlSugar/Interface/IUpdateable.cs @@ -118,6 +118,7 @@ namespace SqlSugar IUpdateable EnableQueryFilter(); IUpdateable Clone(); IUpdateable InnerJoin(Expression> joinExpress); + IUpdateable InnerJoin(Expression> joinExpress,string tableName); UpdateablePage PageSize(int pageSize); IUpdateable In(object[] ids); }