Browse Source

BUG:Updateable(updateList).UpdateColumns(it=>it.Name).SplitTable().ExecuteCommandAsync()

pull/40/head
sunkaixuan 1 year ago
parent
commit
743244bdd3
  1. 1
      Src/Asp.Net/SqlSugar/Abstract/UpdateProvider/SplitTableUpdateByObjectProvider.cs

1
Src/Asp.Net/SqlSugar/Abstract/UpdateProvider/SplitTableUpdateByObjectProvider.cs

@ -42,6 +42,7 @@ namespace SqlSugar
{ {
var addList = item.Select(it => it.Item).ToList(); var addList = item.Select(it => it.Item).ToList();
result += await this.Context.Updateable(addList) result += await this.Context.Updateable(addList)
.UpdateColumns(updateobj.UpdateBuilder.UpdateColumns?.ToArray())
.IgnoreColumns(this.updateobj.UpdateBuilder.IsNoUpdateNull, this.updateobj.UpdateBuilder.IsOffIdentity, this.updateobj.UpdateBuilder.IsNoUpdateDefaultValue) .IgnoreColumns(this.updateobj.UpdateBuilder.IsNoUpdateNull, this.updateobj.UpdateBuilder.IsOffIdentity, this.updateobj.UpdateBuilder.IsNoUpdateDefaultValue)
.IgnoreColumns(GetIgnoreColumns()).AS(item.Key).ExecuteCommandAsync(); .IgnoreColumns(GetIgnoreColumns()).AS(item.Key).ExecuteCommandAsync();
} }

Loading…
Cancel
Save