mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-06-18 20:08:15 +08:00
- 修复 UpdateJoin null 错误;
This commit is contained in:
@ -578,6 +578,15 @@ namespace base_entity
|
||||
BaseEntity.Initialization(fsql, () => _asyncUow.Value);
|
||||
#endregion
|
||||
|
||||
var updatejoin01 = fsql.Update<User1>()
|
||||
.Join(fsql.Select<UserGroup>(), (a, b) => a.GroupId == b.Id)
|
||||
.Set((a, b) => a.Nickname == b.GroupName)
|
||||
.ExecuteAffrows();
|
||||
var updatejoin02 = fsql.Update<User1>()
|
||||
.Join<UserGroup>((a, b) => a.GroupId == b.Id)
|
||||
.Set((a, b) => a.Nickname == b.GroupName)
|
||||
.ExecuteAffrows();
|
||||
|
||||
var sql1c2 = fsql.Select<User1>()
|
||||
.GroupBy(a => new { a.Nickname, a.Avatar })
|
||||
.WithTempQuery(b => new
|
||||
@ -613,15 +622,6 @@ namespace base_entity
|
||||
|
||||
fsql.UseJsonMap();
|
||||
|
||||
var updatejoin01 = fsql.Update<User1>()
|
||||
.Join(fsql.Select<UserGroup>(), (a, b) => a.GroupId == b.Id)
|
||||
.Set((a, b) => a.Nickname == b.GroupName)
|
||||
.ExecuteAffrows();
|
||||
var updatejoin02 = fsql.Update<User1>()
|
||||
.Join<UserGroup>((a, b) => a.GroupId == b.Id)
|
||||
.Set((a, b) => a.Nickname == b.GroupName)
|
||||
.ExecuteAffrows();
|
||||
|
||||
fsql.Select<User1>().IncludeMany(a => a.Roles);
|
||||
|
||||
var displayNameTb = fsql.CodeFirst.GetTableByEntity(typeof(DeviceCodes));
|
||||
|
Reference in New Issue
Block a user