mirror of
https://github.com/dotnetcore/FreeSql.git
synced 2026-02-05 16:00:52 +08:00
Merge branch 'master' of https://github.com/dotnetcore/FreeSql.wiki
6
骚操作.md
6
骚操作.md
@@ -247,7 +247,7 @@ class Dto {
|
||||
var dto = new [] { 1,2,3 }.Select(a => new Dto { TypeId = a }).ToList();
|
||||
dto.IncludeMany(d => d.GoodsList.Take(10).Where(gd => gd.TypeId == d.TypeId));
|
||||
|
||||
//执行后,dto 每个元素.Vods 将只有 10条记录
|
||||
//执行后,dto 每个元素.GoodsList 将只有 10条记录
|
||||
```
|
||||
|
||||
查询子集合表的部分字段,避免子集合字段过多的问题:
|
||||
@@ -349,7 +349,7 @@ DELETE FROM `T1` WHERE id in (select a.id from T1 a left join Options b on b.t1i
|
||||
|
||||
之前:
|
||||
|
||||
FreeSql.DbContext 和 仓储实现,已经实现了联级保存功能,联级保存功能可实现保存对象的时候,将其【OneToOne】、【OneToMany】、【ManyToMany】导航属性集合也一并保存。
|
||||
FreeSql.DbContext 和 仓储实现,已经实现了联级保存功能,可实现保存对象的时候,将其【OneToOne】、【OneToMany】、【ManyToMany】导航属性集合也一并保存。
|
||||
|
||||
全局关闭:
|
||||
|
||||
@@ -422,7 +422,7 @@ var sql1 = fsql.Select<SysModule>()
|
||||
| UserParameters | List\<DbParameter\> | 可附加参数化对象 |
|
||||
| Result | string | 返回表达式函数表示的 SQL 字符串 |
|
||||
|
||||
> 当扩展方法返回值为 string 时,其返回值也可以当作 context.Value.Result 功能
|
||||
> 当扩展方法返回值为 string 时,其返回值也可以当作 context.Value.Result 设置
|
||||
|
||||
> 当不想解析指定参数时,使用特性 \[RawValue\] 标记
|
||||
|
||||
|
||||
Reference in New Issue
Block a user