标签:for csharp soft int wait arp 图片 turn name
地址:https://docs.microsoft.com/en-us/dotnet/csharp/linq/perform-left-outer-joins
①创建两张表和一些基础数据做我们的测试
②我们的 查询语句
[HttpGet] public async Task<IHttpActionResult> Init() { var linq = from a in db.JoinAs join b in db.JoinBs on a.ACode equals b.ACode into gj from ee in gj.DefaultIfEmpty() select new { AName = a.AName, ACode = a.ACode, BName = ee.BName ?? "" }; return await Task.FromResult(Ok(new { data = linq })); }
查询结果:
③ 查看我们的Linq翻译的sql语句,LinqPad
标签:for csharp soft int wait arp 图片 turn name
原文地址:https://www.cnblogs.com/Sea1ee/p/10496326.html