内链接inner join

示例如下:

var query = from tb0 in db.table_0
                        join tb1 in db.table_1 on table_0.关联键 equals table_1.关联键
                        select new { ... };


左链接或右链接,使用DefaultIfEmpty()语法,采用些语法前需要用到into语法

示例如下:
 var  query2 = from tb0 in db.table_0
                    join tb1 in db.table_1  on table_0.关联键 equals table_1.关联键
                    into all
                    from tb2 in all.DefaultIfEmpty()
                    select new { ... };

相关文章:

  • 2021-10-04
  • 2021-06-14
  • 2021-06-30
  • 2021-10-17
  • 2022-12-23
  • 2021-12-05
  • 2021-06-11
猜你喜欢
  • 2022-12-23
  • 2021-10-24
  • 2022-12-23
  • 2022-02-07
  • 2021-05-03
  • 2021-12-18
相关资源
相似解决方案