diff --git a/Src/Asp.NetCore2/SqlSeverTest/UnitTest/UCustom012.cs b/Src/Asp.NetCore2/SqlSeverTest/UnitTest/UCustom012.cs index d67b1b5d3..b4d4097bb 100644 --- a/Src/Asp.NetCore2/SqlSeverTest/UnitTest/UCustom012.cs +++ b/Src/Asp.NetCore2/SqlSeverTest/UnitTest/UCustom012.cs @@ -132,6 +132,23 @@ namespace OrmTest { it.UnitA002 = db.Queryable().SetContext(x => x.orgid, () => it.id, it).First(); }); + + var list4=db.Queryable() + .LeftJoin((x, y) => (x.SchoolId == y.SchoolId)) + .LeftJoin((x,y,z)=>y.SchoolId==y.SchoolId) + .Select((x,y,z) => new UnitView01() + { + Name=x.SchoolName, + },true).ToList(); + } + + public class UnitView01 + { + public string Id { get; set; } + public string SchoolName { get; set; } + public string Name { get; set; } + public int BookId { get; set; } + public int StudentId { get; set; } } public class UnitA001