update url

2881099
2020-11-05 17:24:03 +08:00
parent 861005a363
commit 00740ea5c7
41 changed files with 442 additions and 442 deletions

26
AOP.md

@@ -122,7 +122,7 @@ fsql.Aop.AuditDataReader += (_, e) =>
FreeSql 内部表达式支持非常丰富,对各大数据库的兼容度也做得很好。 FreeSql 内部表达式支持非常丰富,对各大数据库的兼容度也做得很好。
> 有关表达式支持到的程度可点击查看详细wiki[https://github.com/2881099/FreeSql/wiki/%E8%A1%A8%E8%BE%BE%E5%BC%8F%E5%87%BD%E6%95%B0](https://github.com/2881099/FreeSql/wiki/%E8%A1%A8%E8%BE%BE%E5%BC%8F%E5%87%BD%E6%95%B0) > 有关表达式支持到的程度可点击查看详细wiki[%E8%A1%A8%E8%BE%BE%E5%BC%8F%E5%87%BD%E6%95%B0](%E8%A1%A8%E8%BE%BE%E5%BC%8F%E5%87%BD%E6%95%B0)
即便如此丰富也仍然无法满足用户需求FreeSql 对外开放了自定义表达式解析接口: 即便如此丰富也仍然无法满足用户需求FreeSql 对外开放了自定义表达式解析接口:
@@ -137,15 +137,15 @@ fsql.Aop.ParseExpression += (s, e) => {
## 参考资料 ## 参考资料
- [《数据库事务》](https://github.com/2881099/FreeSql/wiki/%e4%ba%8b%e5%8a%a1) - [《数据库事务》](%e4%ba%8b%e5%8a%a1)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
* [《CodeFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/CodeFirst) * [《CodeFirst模式开发介绍》](CodeFirst)
* [《CodeFirst模式之一实体特性》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) * [《CodeFirst模式之一实体特性》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
* [《CodeFirst模式之二FluentApi》](https://github.com/2881099/FreeSql/wiki/FluentApi) * [《CodeFirst模式之二FluentApi》](FluentApi)
* [《CodeFirst模式之三自定义特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) * [《CodeFirst模式之三自定义特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
* [《CodeFirst模式之四类型映射》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) * [《CodeFirst模式之四类型映射》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
* [《CodeFirst模式之五迁移结构》](https://github.com/2881099/FreeSql/wiki/CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84) * [《CodeFirst模式之五迁移结构》](CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84)
- [《DbFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/DbFirst) - [《DbFirst模式开发介绍》](DbFirst)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)

24
API.md

@@ -20,10 +20,10 @@
| 属性 | 返回值 | 说明 | | 属性 | 返回值 | 说明 |
| -- | -- | -- | | -- | -- | -- |
| Ado | IAdo | 数据库访问对象,封装了类似 SqlHelper 操作ExecuteNonQuery/ExecuteScalar/ExecuteConnectTest 等 | | Ado | IAdo | 数据库访问对象,封装了类似 SqlHelper 操作ExecuteNonQuery/ExecuteScalar/ExecuteConnectTest 等 |
| [Aop](https://github.com/2881099/FreeSql/wiki/AOP) | IAop | 所有 AOP 拦截方法都在这里 | | [Aop](AOP) | IAop | 所有 AOP 拦截方法都在这里 |
| [CodeFirst](https://github.com/2881099/FreeSql/wiki/API#CodeFirst) | ICodeFirst | 封装 CodeFirst 模式开发相关方法 | | [CodeFirst](API#CodeFirst) | ICodeFirst | 封装 CodeFirst 模式开发相关方法 |
| [DbFirst](https://github.com/2881099/FreeSql/wiki/API#CodeFirst) | IDbFirst | 封装 DbFirst 模式开发相关方法 | | [DbFirst](API#CodeFirst) | IDbFirst | 封装 DbFirst 模式开发相关方法 |
| [GlobalFilter](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) | GlobalFilter | 全局过滤设置,可默认附加为 Select/Update/Delete 条件 | | [GlobalFilter](%e8%bf%87%e6%bb%a4%e5%99%a8) | GlobalFilter | 全局过滤设置,可默认附加为 Select/Update/Delete 条件 |
| 方法 | 返回值 | 参数 | 说明 | | 方法 | 返回值 | 参数 | 说明 |
| -- | -- | -- | -- | | -- | -- | -- | -- |
@@ -32,15 +32,15 @@
| Update\<TEntity\> | IUpdate\<TEntity\> | 无 | 准备更新数据 | | Update\<TEntity\> | IUpdate\<TEntity\> | 无 | 准备更新数据 |
| Delete\<TEntity\> | IDelete\<TEntity\> | 无 | 准备删除 | | Delete\<TEntity\> | IDelete\<TEntity\> | 无 | 准备删除 |
| InsertOrUpdate\<TEntity\> | IInsertOrUpdate\<TEntity\> | 无 | 插入或更新数据 | | InsertOrUpdate\<TEntity\> | IInsertOrUpdate\<TEntity\> | 无 | 插入或更新数据 |
| Transaction | void | Action | 开启事务(不支持异步),[其他事务](https://github.com/2881099/FreeSql/wiki/%e4%ba%8b%e5%8a%a1) | | Transaction | void | Action | 开启事务(不支持异步),[其他事务](%e4%ba%8b%e5%8a%a1) |
| 扩展方法 | 返回值 | 参数 | 说明 | | 扩展方法 | 返回值 | 参数 | 说明 |
| -- | -- | -- | -- | | -- | -- | -- | -- |
| Select\<T1, T2, ... T10\> | ISelect | 无 | 准备多表查询 | | Select\<T1, T2, ... T10\> | ISelect | 无 | 准备多表查询 |
| [CreateDbContext](https://github.com/2881099/FreeSql/wiki/DbContext) | DbContext | 无 | 创建普通数据上下文档对象,该对象功能类似于 EFCore | | [CreateDbContext](DbContext) | DbContext | 无 | 创建普通数据上下文档对象,该对象功能类似于 EFCore |
| SetDbContextOptions | - | Action | 设置此 IFreeSql 下 DbContext 选项设置 | | SetDbContextOptions | - | Action | 设置此 IFreeSql 下 DbContext 选项设置 |
| [GetRepository](https://github.com/2881099/FreeSql/wiki/Repository)\<TEntity, TKey\> | BaseRepository | 无 | 返回默认仓库功能实现 | | [GetRepository](Repository)\<TEntity, TKey\> | BaseRepository | 无 | 返回默认仓库功能实现 |
| [CreateUnitOfWork](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) | IUnitOfWork | 无 | 创建基于仓储功能的工作单元,务必使用 using 包含使用 | | [CreateUnitOfWork](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) | IUnitOfWork | 无 | 创建基于仓储功能的工作单元,务必使用 using 包含使用 |
--- ---
@@ -73,8 +73,8 @@
| Attach | - | TEntity | 附加实体到状态管理,可用于不查询就更新或删除 | | Attach | - | TEntity | 附加实体到状态管理,可用于不查询就更新或删除 |
| Attach | - | IEnumerable\<TEntity\> | 批量附加实体到状态管理 | | Attach | - | IEnumerable\<TEntity\> | 批量附加实体到状态管理 |
| AttachOnlyPrimary | - | TEntity | 只附加实体的主键数据到状态管理 | | AttachOnlyPrimary | - | TEntity | 只附加实体的主键数据到状态管理 |
| [SaveMany](https://github.com/2881099/FreeSql/wiki/%E8%81%94%E7%BA%A7%E4%BF%9D%E5%AD%98#savemany) | - | TEntity, string | 保存实体的指定 ManyToMany/OneToMany 导航属性(完整对比) | | [SaveMany](%E8%81%94%E7%BA%A7%E4%BF%9D%E5%AD%98#savemany) | - | TEntity, string | 保存实体的指定 ManyToMany/OneToMany 导航属性(完整对比) |
| [BeginEdit](https://github.com/dotnetcore/FreeSql/wiki/%E6%B7%BB%E5%8A%A0%E6%88%96%E4%BF%AE%E6%94%B9#3beginedit-%E6%89%B9%E9%87%8F%E7%BC%96%E8%BE%91) | - | List\<TEntity\> | 准备编辑一个 List 实体 | | [BeginEdit](%E6%B7%BB%E5%8A%A0%E6%88%96%E4%BF%AE%E6%94%B9#3beginedit-%E6%89%B9%E9%87%8F%E7%BC%96%E8%BE%91) | - | List\<TEntity\> | 准备编辑一个 List 实体 |
| EndEdit | int | 无 | 完成编辑数据,进行保存动作 | | EndEdit | int | 无 | 完成编辑数据,进行保存动作 |
> 状态管理,可实现 Update 只更新变化的字段(不更新所有字段),灵活使用 Attach 和 Update 用起来非常舒服。 > 状态管理,可实现 Update 只更新变化的字段(不更新所有字段),灵活使用 Attach 和 Update 用起来非常舒服。
@@ -197,8 +197,8 @@ DbContext 自身 = 完整事务BaseRepository 不一定有事务(可通过
| WithTransaction | \<this\> | DbTransaction | 设置事务对象 | | WithTransaction | \<this\> | DbTransaction | 设置事务对象 |
| WithConnection | \<this\> | DbConnection | 设置连接对象 | | WithConnection | \<this\> | DbConnection | 设置连接对象 |
| ToSql | string | | 返回即将执行的SQL语句 | | ToSql | string | | 返回即将执行的SQL语句 |
| [OnDuplicateKeyUpdate](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) | OnDuplicateKeyUpdate\<T1\> | 无 | MySql 特有的功能On Duplicate Key Update | | [OnDuplicateKeyUpdate](%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) | OnDuplicateKeyUpdate\<T1\> | 无 | MySql 特有的功能On Duplicate Key Update |
| [OnConflictDoUpdate](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) | OnConflictDoUpdate\<T1\> | 无 | PostgreSQL 特有的功能On Conflict Do Update | | [OnConflictDoUpdate](%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) | OnConflictDoUpdate\<T1\> | 无 | PostgreSQL 特有的功能On Conflict Do Update |
| ExecuteAffrows | long | | 执行SQL语句返回影响的行数 | | ExecuteAffrows | long | | 执行SQL语句返回影响的行数 |
| ExecuteIdentity | long | | 执行SQL语句返回自增值 | | ExecuteIdentity | long | | 执行SQL语句返回自增值 |
| ExecuteInserted | List\<T1\> | | 执行SQL语句返回插入后的记录 | | ExecuteInserted | List\<T1\> | | 执行SQL语句返回插入后的记录 |

@@ -45,7 +45,7 @@ public class UserGroup : BaseEntity<UserGroup, int> {
public string GroupName { get; set; } public string GroupName { get; set; }
} }
``` ```
> 有关更多实体的特性配置,请参考资料:https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7 > 有关更多实体的特性配置,请参考资料:%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7
2、定义一个主键 Guid 的实体类型,保存数据时会自动产生有序不重复的 Guid 值(不用自己指定 Guid.NewGuid() 2、定义一个主键 Guid 的实体类型,保存数据时会自动产生有序不重复的 Guid 值(不用自己指定 Guid.NewGuid()
@@ -104,6 +104,6 @@ var items = UserGroup.Where(a => a.Id > 10).ToList();
支持多表查询时,软删除条件会附加在每个表中; 支持多表查询时,软删除条件会附加在每个表中;
> 有关更多查询方法,请参考资料:https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2 > 有关更多查询方法,请参考资料:%e6%9f%a5%e8%af%a2
示范项目https://github.com/2881099/FreeSql/tree/master/Examples/base_entity 示范项目https://github.com/2881099/FreeSql/tree/master/Examples/base_entity

@@ -12,17 +12,17 @@ IFreeSql fsql = new FreeSql.FreeSqlBuilder()
.Build(); //请务必定义成 Singleton 单例模式 .Build(); //请务必定义成 Singleton 单例模式
``` ```
- [《实体特性说明》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) - [《实体特性说明》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
- [《FluentApi享受纯净实体类》](https://github.com/2881099/FreeSql/wiki/FluentApi) - [《FluentApi享受纯净实体类》](FluentApi)
- [《导入数据库特性,懒人专利》](https://github.com/2881099/FreeSql/wiki/%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7) - [《导入数据库特性,懒人专利》](%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7)
- [《Aop自定义特性与其他 ORM 共用特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) - [《Aop自定义特性与其他 ORM 共用特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
- [《类型映射,一览便知》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) - [《类型映射,一览便知》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
- [《导航关系配置》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb) - [《导航关系配置》](%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb)
## 迁移结构 ## 迁移结构
@@ -231,4 +231,4 @@ ALTER TABLE `cccddd`.`Topic2` CHANGE COLUMN `Title2` `Title` VARCHAR(255);
## 参考资料 ## 参考资料
- [《DbFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/DbFirst) - [《DbFirst模式开发介绍》](DbFirst)

@@ -216,7 +216,7 @@ Guid Id 的情况下执行三次命令前两次插入合并执行update
## 联级保存 ## 联级保存
请移步文档[《联级保存》](https://github.com/2881099/FreeSql/wiki/%e8%81%94%e7%ba%a7%e4%bf%9d%e5%ad%98) 请移步文档[《联级保存》](%e8%81%94%e7%ba%a7%e4%bf%9d%e5%ad%98)
## 实体变化事件 ## 实体变化事件
@@ -276,8 +276,8 @@ DbContext.SaveChanges或者 Repository 对实体的 Insert/Update/Delete
## 参考资料 ## 参考资料
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《AOP》](https://github.com/2881099/FreeSql/wiki/AOP) - [《AOP》](AOP)
- [《UnitOfWork》](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) - [《UnitOfWork》](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83)

@@ -44,9 +44,9 @@ var t3 = fsql.DbFirst.GetTableByName("table1");
## 参考资料 ## 参考资料
* [《CodeFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/CodeFirst) * [《CodeFirst模式开发介绍》](CodeFirst)
* [《CodeFirst模式之一实体特性》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) * [《CodeFirst模式之一实体特性》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
* [《CodeFirst模式之二FluentApi》](https://github.com/2881099/FreeSql/wiki/FluentApi) * [《CodeFirst模式之二FluentApi》](FluentApi)
* [《CodeFirst模式之三自定义特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) * [《CodeFirst模式之三自定义特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
* [《CodeFirst模式之四类型映射》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) * [《CodeFirst模式之四类型映射》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
* [《CodeFirst模式之五迁移结构》](https://github.com/2881099/FreeSql/wiki/CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84) * [《CodeFirst模式之五迁移结构》](CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84)

@@ -53,7 +53,7 @@ FreeSql .NET ORM 支持 MySql/SqlServer/PostgreSQL/Oracle/Sqlite/Firebird/达梦
| .NET ORM 导航属性(ManyToOne) | ✔ | ✔ | - | | .NET ORM 导航属性(ManyToOne) | ✔ | ✔ | - |
| .NET ORM 导航属性(OneToMany) | ✔ | ✔ | - | | .NET ORM 导航属性(OneToMany) | ✔ | ✔ | - |
| .NET ORM 导航属性(ManyToMany) | ✔ | - | - | | .NET ORM 导航属性(ManyToMany) | ✔ | - | - |
| .NET ORM 导航属性(Parent) [父子关系的实体类](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2%e7%88%b6%e5%ad%90%e5%85%b3%e7%b3%bb) | ✔ | - | - | | .NET ORM 导航属性(Parent) [父子关系的实体类](%e6%9f%a5%e8%af%a2%e7%88%b6%e5%ad%90%e5%85%b3%e7%b3%bb) | ✔ | - | - |
| .NET ORM 导航属性延时加载、贪婪加载、级联保存 | ✔ | ✔ | - | | .NET ORM 导航属性延时加载、贪婪加载、级联保存 | ✔ | ✔ | - |
| .NET ORM 自定义表达式树解析 | ✔ | - | - | | .NET ORM 自定义表达式树解析 | ✔ | - | - |
| .NET ORM 全局过滤器 | ✔ | ✔ | - | | .NET ORM 全局过滤器 | ✔ | ✔ | - |
@@ -84,7 +84,7 @@ FreeSql .NET ORM 支持 MySql/SqlServer/PostgreSQL/Oracle/Sqlite/Firebird/达梦
| .NET ORM 插入时On Duplicate Key Update | ✔ | - | - | | .NET ORM 插入时On Duplicate Key Update | ✔ | - | - |
| .NET ORM 插入时On Conflict Do Update | ✔ | - | - | | .NET ORM 插入时On Conflict Do Update | ✔ | - | - |
| .NET ORM 批量插入 [性能测试结果参考文档](https://www.cnblogs.com/kellynic/p/10557882.html) | ✔ | - | ✔ | | .NET ORM 批量插入 [性能测试结果参考文档](https://www.cnblogs.com/kellynic/p/10557882.html) | ✔ | - | ✔ |
| .NET ORM 批量插入时,自动分批 [参考文档](https://github.com/dotnetcore/FreeSql/wiki/%E6%B7%BB%E5%8A%A0#2%E6%89%B9%E9%87%8F%E6%8F%92%E5%85%A5) | ✔ | - | - | | .NET ORM 批量插入时,自动分批 [参考文档](%E6%B7%BB%E5%8A%A0#2%E6%89%B9%E9%87%8F%E6%8F%92%E5%85%A5) | ✔ | - | - |
| .NET ORM 批量插入时使用BulkCopy | ✔ | - | - | | .NET ORM 批量插入时使用BulkCopy | ✔ | - | - |
| | | | | | | | | |
| .NET ORM 更新(单条) | ✔ | ✔ | ✔ | | .NET ORM 更新(单条) | ✔ | ✔ | ✔ |
@@ -111,14 +111,14 @@ FreeSql .NET ORM 支持 MySql/SqlServer/PostgreSQL/Oracle/Sqlite/Firebird/达梦
| .NET ORM 删除时,返回插入后的记录 | ✔ | - | - | | .NET ORM 删除时,返回插入后的记录 | ✔ | - | - |
| .NET ORM 级联保存 | ✔ | ✔ | - | | .NET ORM 级联保存 | ✔ | ✔ | - |
| .NET ORM 添加或更新 | ✔ | - | ✔ | | .NET ORM 添加或更新 | ✔ | - | ✔ |
| .NET ORM 添加或更新,自动适配 merge into [参考文档](https://github.com/dotnetcore/FreeSql/wiki/%E6%B7%BB%E5%8A%A0%E6%88%96%E4%BF%AE%E6%94%B9) | ✔ | - | - | | .NET ORM 添加或更新,自动适配 merge into [参考文档](%E6%B7%BB%E5%8A%A0%E6%88%96%E4%BF%AE%E6%94%B9) | ✔ | - | - |
| .NET ORM 批量编辑保存 [参考文档](https://github.com/dotnetcore/FreeSql/wiki/%E6%B7%BB%E5%8A%A0%E6%88%96%E4%BF%AE%E6%94%B9#3beginedit-%E6%89%B9%E9%87%8F%E7%BC%96%E8%BE%91) | ✔ | ✔ | - | | .NET ORM 批量编辑保存 [参考文档](%E6%B7%BB%E5%8A%A0%E6%88%96%E4%BF%AE%E6%94%B9#3beginedit-%E6%89%B9%E9%87%8F%E7%BC%96%E8%BE%91) | ✔ | ✔ | - |
| | | | | | | | | |
| .NET ORM 查询(单条) | ✔ | ✔ | ✔ | | .NET ORM 查询(单条) | ✔ | ✔ | ✔ |
| .NET ORM 查询时,分页 | ✔ | ✔ | ✔ | | .NET ORM 查询时,分页 | ✔ | ✔ | ✔ |
| .NET ORM 查询时,分页支持 SqlServer2008 | ✔ | - | ✔ | | .NET ORM 查询时,分页支持 SqlServer2008 | ✔ | - | ✔ |
| .NET ORM 查询时,动态条件(WhereDynamic) | ✔ | - | ✔ | | .NET ORM 查询时,动态条件(WhereDynamic) | ✔ | - | ✔ |
| .NET ORM 查询时,动态过滤条件(WhereDynamicFilter) [参考文档](https://github.com/dotnetcore/FreeSql/wiki/%E6%9F%A5%E8%AF%A2#%E7%89%B9%E5%88%AB%E4%BB%8B%E7%BB%8D-wheredynamicfilter) | ✔ | - | ✔ | | .NET ORM 查询时,动态过滤条件(WhereDynamicFilter) [参考文档](%E6%9F%A5%E8%AF%A2#%E7%89%B9%E5%88%AB%E4%BB%8B%E7%BB%8D-wheredynamicfilter) | ✔ | - | ✔ |
| .NET ORM 查询时,自动附加全局过滤器条件 | ✔ | - | - | | .NET ORM 查询时,自动附加全局过滤器条件 | ✔ | - | - |
| .NET ORM 查询时,多表条件传播(WhereCascade) | ✔ | - | - | | .NET ORM 查询时,多表条件传播(WhereCascade) | ✔ | - | - |
| .NET ORM 查询时,在 lambda 中使用导航属性 | ✔ | ✔ | - | | .NET ORM 查询时,在 lambda 中使用导航属性 | ✔ | ✔ | - |
@@ -126,7 +126,7 @@ FreeSql .NET ORM 支持 MySql/SqlServer/PostgreSQL/Oracle/Sqlite/Firebird/达梦
| .NET ORM 查询时,传 Sql 作二次查询(WithSql) | ✔ | - | ✔ | | .NET ORM 查询时,传 Sql 作二次查询(WithSql) | ✔ | - | ✔ |
| .NET ORM 查询时,子查询(Exists) | ✔ | - | ✔ | | .NET ORM 查询时,子查询(Exists) | ✔ | - | ✔ |
| .NET ORM 查询时,子查询(In) | ✔ | - | ✔ | | .NET ORM 查询时,子查询(In) | ✔ | - | ✔ |
| .NET ORM 查询时,子查询拼接结果(string.Join) [参考文档](https://github.com/dotnetcore/FreeSql/wiki/%E5%A4%9A%E8%A1%A8%E6%9F%A5%E8%AF%A2#7%E5%AD%90%E8%A1%A8join) | ✔ | - | - | | .NET ORM 查询时,子查询拼接结果(string.Join) [参考文档](%E5%A4%9A%E8%A1%A8%E6%9F%A5%E8%AF%A2#7%E5%AD%90%E8%A1%A8join) | ✔ | - | - |
| .NET ORM 查询时,使用分组聚合(GroupBy/Having) | ✔ | ✔ | ✔ | | .NET ORM 查询时,使用分组聚合(GroupBy/Having) | ✔ | ✔ | ✔ |
| .NET ORM 查询时,使用 Linq To Sql 语法 | ✔ | ✔ | - | | .NET ORM 查询时,使用 Linq To Sql 语法 | ✔ | ✔ | - |
| .NET ORM 查询时,针对树形结构表 [父子关系的实体类](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2%e7%88%b6%e5%ad%90%e5%85%b3%e7%b3%bb) | ✔ | - | - | | .NET ORM 查询时,针对树形结构表 [父子关系的实体类](%e6%9f%a5%e8%af%a2%e7%88%b6%e5%ad%90%e5%85%b3%e7%b3%bb) | ✔ | - | - |

@@ -32,7 +32,7 @@ class TestFluenttb2 {
> 这段配置尽量只执行一次,避免性能损耗 > 这段配置尽量只执行一次,避免性能损耗
参考:[《实体特性说明》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) 参考:[《实体特性说明》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
> FreeSql.DbContext v1.4.0+ 实现了 EfCore FluentApi 99% 相似的语法 > FreeSql.DbContext v1.4.0+ 实现了 EfCore FluentApi 99% 相似的语法
@@ -109,14 +109,14 @@ public class Song {
## 参考资料 ## 参考资料
- [《实体特性说明》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) - [《实体特性说明》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
- [《导入数据库特性,懒人专利》](https://github.com/2881099/FreeSql/wiki/%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7) - [《导入数据库特性,懒人专利》](%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7)
- [《Aop自定义特性与其他 ORM 共用特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) - [《Aop自定义特性与其他 ORM 共用特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
- [《类型映射,一览便知》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) - [《类型映射,一览便知》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
- [《导航关系配置》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb) - [《导航关系配置》](%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb)
- [《CodeFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/CodeFirst) - [《CodeFirst模式开发介绍》](CodeFirst)

44
Home.md

@@ -20,34 +20,34 @@ QQ群4336577(已满)、8578575(在线)、52508226(在线)
## 学习指南 ## 学习指南
FreeSql 除了支持基本的增删查改功能外,还支持基于现有数据库创建模型([DbFirst](https://github.com/2881099/FreeSql/wiki/DbFirst)),和支持基于模型创建数据库([CodeFirst](https://github.com/2881099/FreeSql/wiki/CodeFirst))。 FreeSql 除了支持基本的增删查改功能外,还支持基于现有数据库创建模型([DbFirst](DbFirst)),和支持基于模型创建数据库([CodeFirst](CodeFirst))。
#### 基础 #### 基础
- [《学习FreeSql之一添加数据》](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0) - [《学习FreeSql之一添加数据》](%e6%b7%bb%e5%8a%a0)
- [《学习FreeSql之二删除数据》](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4) - [《学习FreeSql之二删除数据》](%e5%88%a0%e9%99%a4)
- [《学习FreeSql之三修改数据》](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) - [《学习FreeSql之三修改数据》](%e4%bf%ae%e6%94%b9)
- [《学习FreeSql之四查询数据》](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2) - [《学习FreeSql之四查询数据》](%e6%9f%a5%e8%af%a2)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
#### 进阶 #### 进阶
* [《CodeFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/CodeFirst) * [《CodeFirst模式开发介绍》](CodeFirst)
* [《CodeFirst模式之一实体特性》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) * [《CodeFirst模式之一实体特性》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
* [《CodeFirst模式之二FluentApi》](https://github.com/2881099/FreeSql/wiki/FluentApi) * [《CodeFirst模式之二FluentApi》](FluentApi)
* [《CodeFirst模式之三自定义特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) * [《CodeFirst模式之三自定义特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
* [《CodeFirst模式之四类型映射》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) * [《CodeFirst模式之四类型映射》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
* [《CodeFirst模式之五迁移结构》](https://github.com/2881099/FreeSql/wiki/CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84) * [《CodeFirst模式之五迁移结构》](CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84)
- [《DbFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/DbFirst) - [《DbFirst模式开发介绍》](DbFirst)
#### 高级 #### 高级
- [《数据库事务》](https://github.com/2881099/FreeSql/wiki/%e4%ba%8b%e5%8a%a1) - [《数据库事务》](%e4%ba%8b%e5%8a%a1)
- [《使用读写分离》](https://github.com/2881099/FreeSql/wiki/%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb) - [《使用读写分离》](%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
- [《AOP》](https://github.com/2881099/FreeSql/wiki/AOP) - [《AOP》](AOP)

@@ -155,9 +155,9 @@ var t1 = (
## 参考资料 ## 参考资料
- [《多表查询》](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《多表查询》](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)

@@ -68,7 +68,7 @@ public SongsController(IBaseRepository<Song> repos1) {
> 依赖注入的方式可实现全局【过滤与验证】的设定,方便租户功能的设计; > 依赖注入的方式可实现全局【过滤与验证】的设定,方便租户功能的设计;
更多资料:[《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) 更多资料:[《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
## 状态管理 ## 状态管理
@@ -138,7 +138,7 @@ SqlServer 提供的 output inserted 特性,在表使用了自增或数据库
## 联级保存 ## 联级保存
请移步文档[《联级保存》](https://github.com/2881099/FreeSql/wiki/%e8%81%94%e7%ba%a7%e4%bf%9d%e5%ad%98) 请移步文档[《联级保存》](%e8%81%94%e7%ba%a7%e4%bf%9d%e5%ad%98)
## API ## API
@@ -169,23 +169,23 @@ SqlServer 提供的 output inserted 特性,在表使用了自增或数据库
| Attach | - | TEntity | 附加实体到状态管理,可用于不查询就更新或删除 | | Attach | - | TEntity | 附加实体到状态管理,可用于不查询就更新或删除 |
| Attach | - | IEnumerable\<TEntity\> | 批量附加实体到状态管理 | | Attach | - | IEnumerable\<TEntity\> | 批量附加实体到状态管理 |
| AttachOnlyPrimary | - | TEntity | 只附加实体的主键数据到状态管理 | | AttachOnlyPrimary | - | TEntity | 只附加实体的主键数据到状态管理 |
| [SaveMany](https://github.com/2881099/FreeSql/wiki/%E8%81%94%E7%BA%A7%E4%BF%9D%E5%AD%98#savemany) | - | TEntity, string | 保存实体的指定 ManyToMany/OneToMany 导航属性(完整对比) | | [SaveMany](%E8%81%94%E7%BA%A7%E4%BF%9D%E5%AD%98#savemany) | - | TEntity, string | 保存实体的指定 ManyToMany/OneToMany 导航属性(完整对比) |
| [BeginEdit](https://github.com/dotnetcore/FreeSql/wiki/%E6%B7%BB%E5%8A%A0%E6%88%96%E4%BF%AE%E6%94%B9#3beginedit-%E6%89%B9%E9%87%8F%E7%BC%96%E8%BE%91) | - | List\<TEntity\> | 准备编辑一个 List 实体 | | [BeginEdit](%E6%B7%BB%E5%8A%A0%E6%88%96%E4%BF%AE%E6%94%B9#3beginedit-%E6%89%B9%E9%87%8F%E7%BC%96%E8%BE%91) | - | List\<TEntity\> | 准备编辑一个 List 实体 |
| EndEdit | int | 无 | 完成编辑数据,进行保存动作 | | EndEdit | int | 无 | 完成编辑数据,进行保存动作 |
> 状态管理,可实现 Update 只更新变化的字段(不更新所有字段),灵活使用 Attach 和 Update 用起来非常舒服。 > 状态管理,可实现 Update 只更新变化的字段(不更新所有字段),灵活使用 Attach 和 Update 用起来非常舒服。
## 参考资料 ## 参考资料
- [《学习FreeSql之一添加数据》](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0) - [《学习FreeSql之一添加数据》](%e6%b7%bb%e5%8a%a0)
- [《学习FreeSql之二删除数据》](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4) - [《学习FreeSql之二删除数据》](%e5%88%a0%e9%99%a4)
- [《学习FreeSql之三修改数据》](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) - [《学习FreeSql之三修改数据》](%e4%bf%ae%e6%94%b9)
- [《学习FreeSql之四查询数据》](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2) - [《学习FreeSql之四查询数据》](%e6%9f%a5%e8%af%a2)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《AOP》](https://github.com/2881099/FreeSql/wiki/AOP) - [《AOP》](AOP)
- [《UnitOfWork》](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) - [《UnitOfWork》](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83)
- [《DbContext》](https://github.com/2881099/FreeSql/wiki/DbContext) - [《DbContext》](DbContext)

@@ -1,62 +1,62 @@
## 基础文档 ## 基础文档
* [入门](https://github.com/2881099/FreeSql/wiki/%e5%85%a5%e9%97%a8) * [入门](%e5%85%a5%e9%97%a8)
* [安装](https://github.com/2881099/FreeSql/wiki/%e5%ae%89%e8%a3%85) * [安装](%e5%ae%89%e8%a3%85)
* [添加](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0) * [添加](%e6%b7%bb%e5%8a%a0)
* [单条添加](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0#1%E5%8D%95%E6%9D%A1%E6%8F%92%E5%85%A5) * [单条添加](%e6%b7%bb%e5%8a%a0#1%E5%8D%95%E6%9D%A1%E6%8F%92%E5%85%A5)
* [批量添加](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0#2%E6%89%B9%E9%87%8F%E6%8F%92%E5%85%A5) * [批量添加](%e6%b7%bb%e5%8a%a0#2%E6%89%B9%E9%87%8F%E6%8F%92%E5%85%A5)
* [删除](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4) * [删除](%e5%88%a0%e9%99%a4)
* [修改](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) * [修改](%e4%bf%ae%e6%94%b9)
* [更新实体](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9#2%E6%9B%B4%E6%96%B0%E5%AE%9E%E4%BD%93) * [更新实体](%e4%bf%ae%e6%94%b9#2%E6%9B%B4%E6%96%B0%E5%AE%9E%E4%BD%93)
* [指定列更新](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9#1%E6%9B%B4%E6%96%B0%E6%8C%87%E5%AE%9A%E5%88%97) * [指定列更新](%e4%bf%ae%e6%94%b9#1%E6%9B%B4%E6%96%B0%E6%8C%87%E5%AE%9A%E5%88%97)
* [添加或修改✨](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) * [添加或修改✨](%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9)
* [查询](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2) * [查询](%e6%9f%a5%e8%af%a2)
* [分页](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e9%a1%b5%e6%9f%a5%e8%af%a2) * [分页](%e5%88%86%e9%a1%b5%e6%9f%a5%e8%af%a2)
* [单表](https://github.com/2881099/FreeSql/wiki/%e5%8d%95%e8%a1%a8%e6%9f%a5%e8%af%a2) * [单表](%e5%8d%95%e8%a1%a8%e6%9f%a5%e8%af%a2)
* [多表](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) * [多表](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
* [分组聚合](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e7%bb%84%e8%81%9a%e5%90%88%e6%9f%a5%e8%af%a2) * [分组聚合](%e5%88%86%e7%bb%84%e8%81%9a%e5%90%88%e6%9f%a5%e8%af%a2)
* [返回数据✨](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) * [返回数据✨](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
* [延时加载](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) * [延时加载](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
* [贪婪加载✨](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) * [贪婪加载✨](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
* [LinqToSql](https://github.com/2881099/FreeSql/wiki/LinqToSql) * [LinqToSql](LinqToSql)
* [查询父子关系✨](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2%e7%88%b6%e5%ad%90%e5%85%b3%e7%b3%bb) * [查询父子关系✨](%e6%9f%a5%e8%af%a2%e7%88%b6%e5%ad%90%e5%85%b3%e7%b3%bb)
* [仓储层Repository](https://github.com/2881099/FreeSql/wiki/Repository) * [仓储层Repository](Repository)
* [UnitOfWork](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) * [UnitOfWork](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83)
* [联级保存](https://github.com/2881099/FreeSql/wiki/%e8%81%94%e7%ba%a7%e4%bf%9d%e5%ad%98) * [联级保存](%e8%81%94%e7%ba%a7%e4%bf%9d%e5%ad%98)
* [DbContext](https://github.com/2881099/FreeSql/wiki/DbContext) * [DbContext](DbContext)
* [CodeFirst](https://github.com/2881099/FreeSql/wiki/CodeFirst) * [CodeFirst](CodeFirst)
* [实体特性✨](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) * [实体特性✨](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
* [FluentApi](https://github.com/2881099/FreeSql/wiki/FluentApi) * [FluentApi](FluentApi)
* [自定义特性](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) * [自定义特性](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
* [类型映射](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) * [类型映射](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
* [导航配置✨](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb) * [导航配置✨](%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb)
* [迁移结构](https://github.com/2881099/FreeSql/wiki/CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84) * [迁移结构](CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84)
* [DbFirst](https://github.com/2881099/FreeSql/wiki/DbFirst) * [DbFirst](DbFirst)
* [表达式函数](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) * [表达式函数](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
* [字符串](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%e5%ad%97%e7%ac%a6%e4%b8%b2) * [字符串](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%e5%ad%97%e7%ac%a6%e4%b8%b2)
* [日期/时间](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%e6%97%a5%e6%9c%9f) * [日期/时间](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%e6%97%a5%e6%9c%9f)
* [其他](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0%e5%85%a8%e8%a7%88) * [其他](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0%e5%85%a8%e8%a7%88)
* [自定义函数](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%E8%87%AA%E5%AE%9A%E4%B9%89%E8%A7%A3%E6%9E%90) * [自定义函数](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%E8%87%AA%E5%AE%9A%E4%B9%89%E8%A7%A3%E6%9E%90)
* [事务](https://github.com/2881099/FreeSql/wiki/%e4%ba%8b%e5%8a%a1) * [事务](%e4%ba%8b%e5%8a%a1)
* [过滤器](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) * [过滤器](%e8%bf%87%e6%bb%a4%e5%99%a8)
* [AOP✨](https://github.com/2881099/FreeSql/wiki/AOP) * [AOP✨](AOP)
* [读写分离](https://github.com/2881099/FreeSql/wiki/%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb) * [读写分离](%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb)
* [分表分库](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) * [分表分库](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
* [租户](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) * [租户](%e7%a7%9f%e6%88%b7)
* [性能](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) * [性能](%e6%80%a7%e8%83%bd)
* [*你不知道的功能✨*](https://github.com/2881099/FreeSql/wiki/%E9%AA%9A%E6%93%8D%E4%BD%9C) * [*你不知道的功能✨*](%E9%AA%9A%E6%93%8D%E4%BD%9C)
* [API参考](https://github.com/2881099/FreeSql/wiki/API) * [API参考](API)
## 使用指南 ## 使用指南
* Dapper比较 * Dapper比较
* [EntityFramework比较](https://github.com/2881099/FreeSql/wiki/EntityFramework%e6%af%94%e8%be%83) * [EntityFramework比较](EntityFramework%e6%af%94%e8%be%83)
## 学习与交流 ## 学习与交流
* [常见问题](https://github.com/2881099/FreeSql/wiki/%e5%b8%b8%e8%a7%81%e9%97%ae%e9%a2%98) * [常见问题](%e5%b8%b8%e8%a7%81%e9%97%ae%e9%a2%98)
* [提交Issue](https://github.com/2881099/FreeSql/issues/new) * [提交Issue](https://github.com/2881099/FreeSql/issues/new)
## 信息 ## 信息
* [更新日志](https://github.com/2881099/FreeSql/wiki/%e6%9b%b4%e6%96%b0%e6%97%a5%e5%bf%97) * [更新日志](%e6%9b%b4%e6%96%b0%e6%97%a5%e5%bf%97)

@@ -156,14 +156,14 @@ using (var uowManager = new UnitOfWorkManager(fsql)) //使用 UnitOfWorkManager
## 更多资料 ## 更多资料
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《读写分离》](https://github.com/2881099/FreeSql/wiki/%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb) - [《读写分离》](%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《AOP》](https://github.com/2881099/FreeSql/wiki/AOP) - [《AOP》](AOP)
- [《UnitOfWork》](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) - [《UnitOfWork》](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83)
- [《学习FreeSql之一添加数据》](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0) - [《学习FreeSql之一添加数据》](%e6%b7%bb%e5%8a%a0)
- [《学习FreeSql之二删除数据》](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4) - [《学习FreeSql之二删除数据》](%e5%88%a0%e9%99%a4)
- [《学习FreeSql之三修改数据》](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) - [《学习FreeSql之三修改数据》](%e4%bf%ae%e6%94%b9)

@@ -241,13 +241,13 @@ UPDATE `T1` SET Title = '111' WHERE id in (select a.id from T1 a left join Optio
## 参考资料 ## 参考资料
- [《数据库事务》](https://github.com/2881099/FreeSql/wiki/%e4%ba%8b%e5%8a%a1) - [《数据库事务》](%e4%ba%8b%e5%8a%a1)
- [《学习FreeSql之一添加数据》](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0) - [《学习FreeSql之一添加数据》](%e6%b7%bb%e5%8a%a0)
- [《学习FreeSql之二删除数据》](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4) - [《学习FreeSql之二删除数据》](%e5%88%a0%e9%99%a4)
- [《学习FreeSql之三查询数据》](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2) - [《学习FreeSql之三查询数据》](%e6%9f%a5%e8%af%a2)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《UnitOfWork》](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) - [《UnitOfWork》](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83)
# API # API

@@ -8,7 +8,7 @@ QQ群4336577(已满)、8578575(在线)、52508226(在线)
FreeSql 使用模型执行数据访问,模型由实体类表示数据库表或视图,用于查询和保存数据。 FreeSql 使用模型执行数据访问,模型由实体类表示数据库表或视图,用于查询和保存数据。
可从现有数据库生成实体模型FreeSql 提供 IDbFirst 接口实现[生成实体模型](https://github.com/2881099/FreeSql/wiki/DbFirst)。 可从现有数据库生成实体模型FreeSql 提供 IDbFirst 接口实现[生成实体模型](DbFirst)。
或者手动创建模型,基于模型创建或修改数据库,提供 ICodeFirst 同步结构的 API甚至可以做到开发阶段自动同步 或者手动创建模型,基于模型创建或修改数据库,提供 ICodeFirst 同步结构的 API甚至可以做到开发阶段自动同步
@@ -26,7 +26,7 @@ public class Blog {
## 安装包 ## 安装包
FreeSql.Provider.xxx([可选的驱动](https://github.com/dotnetcore/FreeSql/wiki/%E5%AE%89%E8%A3%85)) FreeSql.Provider.xxx([可选的驱动](%E5%AE%89%E8%A3%85))
```bash ```bash
dotnet add packages FreeSql dotnet add packages FreeSql
dotnet add packages FreeSql.Provider.Sqlite dotnet add packages FreeSql.Provider.Sqlite
@@ -66,7 +66,7 @@ public class DB
## 迁移 ## 迁移
程序运行中FreeSql会检查AutoSyncStructure参数以此条件判断是否对比实体与数据库结构之间的变化达到自动迁移的目的,更多请查看[CodeFirst](https://github.com/dotnetcore/FreeSql/wiki/CodeFirst)文档, 程序运行中FreeSql会检查AutoSyncStructure参数以此条件判断是否对比实体与数据库结构之间的变化达到自动迁移的目的,更多请查看[CodeFirst](CodeFirst)文档,
> 注意:谨慎、谨慎、谨慎在生产环境中使用该功能。 > 注意:谨慎、谨慎、谨慎在生产环境中使用该功能。
@@ -151,11 +151,11 @@ fsql.Delete<Blog>()
## 参考资料 ## 参考资料
- [《安装FreeSql》](https://github.com/2881099/FreeSql/wiki/%e5%ae%89%e8%a3%85) - [《安装FreeSql》](%e5%ae%89%e8%a3%85)
- [《学习FreeSql之一添加数据》](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0) - [《学习FreeSql之一添加数据》](%e6%b7%bb%e5%8a%a0)
- [《学习FreeSql之二删除数据》](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4) - [《学习FreeSql之二删除数据》](%e5%88%a0%e9%99%a4)
- [《学习FreeSql之三修改数据》](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) - [《学习FreeSql之三修改数据》](%e4%bf%ae%e6%94%b9)
- [《学习FreeSql之四查询数据》](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2) - [《学习FreeSql之四查询数据》](%e6%9f%a5%e8%af%a2)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《UnitOfWork》](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) - [《UnitOfWork》](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83)

@@ -53,13 +53,13 @@ var list = fsql.Select<Topic>()
## 参考资料 ## 参考资料
- [《多表查询》](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《多表查询》](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《LinqToSql》](https://github.com/2881099/FreeSql/wiki/LinqToSql) - [《LinqToSql》](LinqToSql)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)

@@ -133,15 +133,15 @@ class YourDefaultRepository<T, TKey> : BaseRepository<T, TKey> where T : class
## 参考资料 ## 参考资料
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《读写分离》](https://github.com/2881099/FreeSql/wiki/%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb) - [《读写分离》](%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《AOP》](https://github.com/2881099/FreeSql/wiki/AOP) - [《AOP》](AOP)
- [《UnitOfWork》](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) - [《UnitOfWork》](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83)
- [《学习FreeSql之一添加数据》](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0) - [《学习FreeSql之一添加数据》](%e6%b7%bb%e5%8a%a0)
- [《学习FreeSql之二删除数据》](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4) - [《学习FreeSql之二删除数据》](%e5%88%a0%e9%99%a4)
- [《学习FreeSql之三修改数据》](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) - [《学习FreeSql之三修改数据》](%e4%bf%ae%e6%94%b9)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)

@@ -49,14 +49,14 @@ SqlServer 2012+ 版本,使用最新的 fetch next rows 分页;
## 参考资料 ## 参考资料
- [《多表查询》](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《多表查询》](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《LinqToSql》](https://github.com/2881099/FreeSql/wiki/LinqToSql) - [《LinqToSql》](LinqToSql)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)

@@ -84,12 +84,12 @@ DELETE FROM `T1` WHERE id in (select a.id from T1 a left join Options b on b.t1i
## 参考资料 ## 参考资料
- [《数据库事务》](https://github.com/2881099/FreeSql/wiki/%e4%ba%8b%e5%8a%a1) - [《数据库事务》](%e4%ba%8b%e5%8a%a1)
- [《学习FreeSql之一添加数据》](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0) - [《学习FreeSql之一添加数据》](%e6%b7%bb%e5%8a%a0)
- [《学习FreeSql之二修改数据》](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) - [《学习FreeSql之二修改数据》](%e4%bf%ae%e6%94%b9)
- [《学习FreeSql之三查询数据》](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2) - [《学习FreeSql之三查询数据》](%e6%9f%a5%e8%af%a2)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
## API ## API

@@ -52,13 +52,13 @@ fsql.Select<Topic>()
## 参考资料 ## 参考资料
- [《多表查询》](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《多表查询》](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《LinqToSql》](https://github.com/2881099/FreeSql/wiki/LinqToSql) - [《LinqToSql》](LinqToSql)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)

@@ -41,7 +41,7 @@ fsql.Select<Topic>()
//LEFT JOIN `CategoryType` a__Category__Parent ON a__Category__Parent.`Id` = a__Category.`ParentId` //LEFT JOIN `CategoryType` a__Category__Parent ON a__Category__Parent.`Id` = a__Category.`ParentId`
``` ```
> 提示:正确配置[导航关系](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb)后,不再需要手工调用 LeftJoin > 提示:正确配置[导航关系](%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb)后,不再需要手工调用 LeftJoin
## 2、复杂联表 ## 2、复杂联表
```csharp ```csharp
@@ -212,7 +212,7 @@ WHERE t1.IsDeleted = 0
- 子查询,一对多、多对多、自定义的子查询; - 子查询,一对多、多对多、自定义的子查询;
- Join 查询导航属性、自定义的Join查询 - Join 查询导航属性、自定义的Join查询
- Include/[IncludeMany](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd#3%E5%AF%BC%E8%88%AA%E5%B1%9E%E6%80%A7-onetomanymanytomany) 的子集合查询; - Include/[IncludeMany](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd#3%E5%AF%BC%E8%88%AA%E5%B1%9E%E6%80%A7-onetomanymanytomany) 的子集合查询;
> 暂时不支持【延时属性】的广播; > 暂时不支持【延时属性】的广播;
@@ -220,12 +220,12 @@ WHERE t1.IsDeleted = 0
## 参考资料 ## 参考资料
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《LinqToSql》](https://github.com/2881099/FreeSql/wiki/LinqToSql) - [《LinqToSql》](LinqToSql)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)

@@ -12,8 +12,8 @@ dotnet add package FreeSql
| Package Name | Version | 说明 | | Package Name | Version | 说明 |
|--------------| ------- | --- | |--------------| ------- | --- |
| [FreeSql.Repository](https://github.com/2881099/FreeSql/wiki/Repository) | NETStandard2.0、net45、net40 | 通用仓储 + UnitOfWork 实现 | | [FreeSql.Repository](Repository) | NETStandard2.0、net45、net40 | 通用仓储 + UnitOfWork 实现 |
| [FreeSql.DbContext](https://github.com/2881099/FreeSql/wiki/DbContext) | NETStandard2.0、net45、net40 | EFCore 的使用风格实现 | | [FreeSql.DbContext](DbContext) | NETStandard2.0、net45、net40 | EFCore 的使用风格实现 |
| FreeSql.Provider.MySql | NETStandard2.0、net45、net40 | 基于 MySql.DataOracle官方 | | FreeSql.Provider.MySql | NETStandard2.0、net45、net40 | 基于 MySql.DataOracle官方 |
| FreeSql.Provider.MySqlConnector | NETStandard2.0、net45 | 基于 MySqlConnector | | FreeSql.Provider.MySqlConnector | NETStandard2.0、net45 | 基于 MySqlConnector |
| FreeSql.Provider.PostgreSQL | NETStandard2.0、net45 | 基于 PostgreSQL 9.5+ | | FreeSql.Provider.PostgreSQL | NETStandard2.0、net45 | 基于 PostgreSQL 9.5+ |
@@ -35,34 +35,34 @@ dotnet add package FreeSql
## 学习指南 ## 学习指南
FreeSql 除了支持基本的增删查改功能外,还支持基于现有数据库创建模型([DbFirst](https://github.com/2881099/FreeSql/wiki/DbFirst)),和支持基于模型创建数据库([CodeFirst](https://github.com/2881099/FreeSql/wiki/CodeFirst))。 FreeSql 除了支持基本的增删查改功能外,还支持基于现有数据库创建模型([DbFirst](DbFirst)),和支持基于模型创建数据库([CodeFirst](CodeFirst))。
#### 基础 #### 基础
- [《学习FreeSql之一添加数据》](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0) - [《学习FreeSql之一添加数据》](%e6%b7%bb%e5%8a%a0)
- [《学习FreeSql之二删除数据》](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4) - [《学习FreeSql之二删除数据》](%e5%88%a0%e9%99%a4)
- [《学习FreeSql之三修改数据》](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) - [《学习FreeSql之三修改数据》](%e4%bf%ae%e6%94%b9)
- [《学习FreeSql之四查询数据》](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2) - [《学习FreeSql之四查询数据》](%e6%9f%a5%e8%af%a2)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
#### 进阶 #### 进阶
* [《CodeFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/CodeFirst) * [《CodeFirst模式开发介绍》](CodeFirst)
* [《CodeFirst模式之一实体特性》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) * [《CodeFirst模式之一实体特性》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
* [《CodeFirst模式之二FluentApi》](https://github.com/2881099/FreeSql/wiki/FluentApi) * [《CodeFirst模式之二FluentApi》](FluentApi)
* [《CodeFirst模式之三自定义特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) * [《CodeFirst模式之三自定义特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
* [《CodeFirst模式之四类型映射》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) * [《CodeFirst模式之四类型映射》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
* [《CodeFirst模式之五迁移结构》](https://github.com/2881099/FreeSql/wiki/CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84) * [《CodeFirst模式之五迁移结构》](CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84)
- [《DbFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/DbFirst) - [《DbFirst模式开发介绍》](DbFirst)
#### 高级 #### 高级
- [《数据库事务》](https://github.com/2881099/FreeSql/wiki/%e4%ba%8b%e5%8a%a1) - [《数据库事务》](%e4%ba%8b%e5%8a%a1)
- [《使用读写分离》](https://github.com/2881099/FreeSql/wiki/%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb) - [《使用读写分离》](%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
- [《AOP》](https://github.com/2881099/FreeSql/wiki/AOP) - [《AOP》](AOP)

@@ -165,12 +165,12 @@ class Tag {
Song、Tag、Song_tag这三个实体使用了 OneToMany、ManyToOne、Parent、ManyToMany 4种关系。 Song、Tag、Song_tag这三个实体使用了 OneToMany、ManyToOne、Parent、ManyToMany 4种关系。
- [《实体特性说明》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) - [《实体特性说明》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
- [《FluentApi享受纯净实体类》](https://github.com/2881099/FreeSql/wiki/FluentApi) - [《FluentApi享受纯净实体类》](FluentApi)
- [《从数据库导入特性,懒人专利》](https://github.com/2881099/FreeSql/wiki/%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7) - [《从数据库导入特性,懒人专利》](%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7)
- [《Aop自定义特性与其他 ORM 共用特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) - [《Aop自定义特性与其他 ORM 共用特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
- [《类型映射,一览便知》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) - [《类型映射,一览便知》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)

@@ -279,14 +279,14 @@ FreeSql CodeFirst 支持将 c# 代码内的注释,迁移至数据库的备注
## 参考资料 ## 参考资料
- [《FluentApi享受纯净实体类》](https://github.com/2881099/FreeSql/wiki/FluentApi) - [《FluentApi享受纯净实体类》](FluentApi)
- [《导入数据库特性,懒人专利》](https://github.com/2881099/FreeSql/wiki/%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7) - [《导入数据库特性,懒人专利》](%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7)
- [《Aop自定义特性与其他 ORM 共用特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) - [《Aop自定义特性与其他 ORM 共用特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
- [《类型映射,一览便知》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) - [《类型映射,一览便知》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
- [《导航关系配置》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb) - [《导航关系配置》](%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb)
- [《CodeFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/CodeFirst) - [《CodeFirst模式开发介绍》](CodeFirst)

@@ -16,14 +16,14 @@ fsql.CodeFirst.IsConfigEntityFromDbFirst = true;
## 参考资料 ## 参考资料
- [《实体特性说明》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) - [《实体特性说明》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
- [《FluentApi享受纯净实体类》](https://github.com/2881099/FreeSql/wiki/FluentApi) - [《FluentApi享受纯净实体类》](FluentApi)
- [《Aop自定义特性与其他 ORM 共用特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) - [《Aop自定义特性与其他 ORM 共用特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
- [《类型映射,一览便知》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) - [《类型映射,一览便知》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
- [《导航关系配置》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb) - [《导航关系配置》](%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb)
- [《CodeFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/CodeFirst) - [《CodeFirst模式开发介绍》](CodeFirst)

@@ -121,10 +121,10 @@ DbContext.SaveChanges或者 Repository 对实体的 Insert/Update/Delete
## 参考资料 ## 参考资料
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《读写分离》](https://github.com/2881099/FreeSql/wiki/%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb) - [《读写分离》](%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《AOP》](https://github.com/2881099/FreeSql/wiki/AOP) - [《AOP》](AOP)
- [《DbContext》](https://github.com/2881099/FreeSql/wiki/DbContext) - [《DbContext》](DbContext)

@@ -119,10 +119,10 @@ limit 0,1))
## 参考资料 ## 参考资料
- [《多表查询》](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《多表查询》](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)

@@ -202,14 +202,14 @@ public void QueryList() {
> 更多测试源码FreeSql/FreeSql.Tests.PerformanceTests/MySqlAdoTest.cs > 更多测试源码FreeSql/FreeSql.Tests.PerformanceTests/MySqlAdoTest.cs
- [《数据库事务》](https://github.com/2881099/FreeSql/wiki/%e4%ba%8b%e5%8a%a1) - [《数据库事务》](%e4%ba%8b%e5%8a%a1)
- [《使用读写分离》](https://github.com/2881099/FreeSql/wiki/%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb) - [《使用读写分离》](%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
- [《AOP》](https://github.com/2881099/FreeSql/wiki/AOP) - [《AOP》](AOP)

@@ -176,8 +176,8 @@
- 修复 ISelect.ToDataTable(lambda) 未使用 AsProperty 返回数据; - 修复 ISelect.ToDataTable(lambda) 未使用 AsProperty 返回数据;
- 修复 IUpdate.Set(a => a.xx = null) 表达式解析 bug#311 - 修复 IUpdate.Set(a => a.xx = null) 表达式解析 bug#311
- 修复 Enum 类型无元素时的错误; - 修复 Enum 类型无元素时的错误;
- **增加 IFreeSql.InsertOrUpdate 方法 [wiki](https://github.com/dotnetcore/FreeSql/wiki/%E6%B7%BB%E5%8A%A0%E6%88%96%E4%BF%AE%E6%94%B9)** - **增加 IFreeSql.InsertOrUpdate 方法 [wiki](%E6%B7%BB%E5%8A%A0%E6%88%96%E4%BF%AE%E6%94%B9)**
- **增加 ISelect.WhereDynamicFilter 方法实现动态过滤条件(与前端交互)[wiki](https://github.com/dotnetcore/FreeSql/wiki/%E6%9F%A5%E8%AF%A2)** - **增加 ISelect.WhereDynamicFilter 方法实现动态过滤条件(与前端交互)[wiki](%E6%9F%A5%E8%AF%A2)**
- **增加 表达式解析 yyyyMMdd 常用 c# 日期格式化;** - **增加 表达式解析 yyyyMMdd 常用 c# 日期格式化;**
- 增加 WhereCascade/GlobalFilter 表达式子查询的支持; - 增加 WhereCascade/GlobalFilter 表达式子查询的支持;
- 增加 \[Description\] 元数据注释,优先级低于 c# 代码注释; - 增加 \[Description\] 元数据注释,优先级低于 c# 代码注释;
@@ -333,14 +333,14 @@ po
- 兼容 Vb.Net 无法使用 IncludeMany 的问题; - 兼容 Vb.Net 无法使用 IncludeMany 的问题;
- 兼容 Vb.Net 无法使用 int? 类型 = 等号表达式解析; - 兼容 Vb.Net 无法使用 int? 类型 = 等号表达式解析;
- 优化 实体基类的属性位置,优先排在最前面; - 优化 实体基类的属性位置,优先排在最前面;
- 整理 实体类 Ctor 有构造函数的映射处理;[wiki](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae#dto-%E6%98%A0%E5%B0%84%E6%9F%A5%E8%AF%A2) - 整理 实体类 Ctor 有构造函数的映射处理;[wiki](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae#dto-%E6%98%A0%E5%B0%84%E6%9F%A5%E8%AF%A2)
- 优化 实体属性,支持 protected set 属性; - 优化 实体属性,支持 protected set 属性;
- 修复 Ado.Query 查询字段重复时报错;#162 - 修复 Ado.Query 查询字段重复时报错;#162
- **增加 FreeSql.Provider.MsAccess 支持 Access 数据库操作,已通过 2003/2007 版本测试;** - **增加 FreeSql.Provider.MsAccess 支持 Access 数据库操作,已通过 2003/2007 版本测试;**
## v0.12.21 ## v0.12.21
- 增加 Where In 表达式解析;[wiki](https://github.com/2881099/FreeSql/wiki/%E5%A4%9A%E8%A1%A8%E6%9F%A5%E8%AF%A2#8%E5%AD%90%E8%A1%A8-exists) - 增加 Where In 表达式解析;[wiki](%E5%A4%9A%E8%A1%A8%E6%9F%A5%E8%AF%A2#8%E5%AD%90%E8%A1%A8-exists)
- **增加 FreeSqlBuilder.UseConnectionFactory 自定义数据库连接对象的创建方法;** - **增加 FreeSqlBuilder.UseConnectionFactory 自定义数据库连接对象的创建方法;**
- 兼容 Vb.Net 表达式解析字符串 = 判断; - 兼容 Vb.Net 表达式解析字符串 = 判断;
- 优化 GlobalFilter 过滤器表达式 bool 解析; - 优化 GlobalFilter 过滤器表达式 bool 解析;
@@ -403,14 +403,14 @@ po
## v0.12.5 ## v0.12.5
- **增加 实体特性 [Column(ServerTime = DateTimeKind.Utc)] 使用数据库时间执行插入数据;**[wiki](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7#%E6%9C%8D%E5%8A%A1%E5%99%A8%E6%97%B6%E9%97%B4servertime) - **增加 实体特性 [Column(ServerTime = DateTimeKind.Utc)] 使用数据库时间执行插入数据;**[wiki](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7#%E6%9C%8D%E5%8A%A1%E5%99%A8%E6%97%B6%E9%97%B4servertime)
- 修复 ToList(a => new Dto { .. }) 在使用 GroupBy 之后报错的 bug - 修复 ToList(a => new Dto { .. }) 在使用 GroupBy 之后报错的 bug
- 修复 注释迁移到数据库,在 asp.net 4.7 无效的问题; - 修复 注释迁移到数据库,在 asp.net 4.7 无效的问题;
- 修复 批量插入 Values 数量限制超出的判断; - 修复 批量插入 Values 数量限制超出的判断;
## v0.12.3 ## v0.12.3
- 增加 ICodeFirst.IsGenerateCommandParameterWithLambda 选项,开启表达式解析的命令参数化;[wiki](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%E5%91%BD%E4%BB%A4%E5%8F%82%E6%95%B0%E5%8C%96v0121) - 增加 ICodeFirst.IsGenerateCommandParameterWithLambda 选项,开启表达式解析的命令参数化;[wiki](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%E5%91%BD%E4%BB%A4%E5%8F%82%E6%95%B0%E5%8C%96v0121)
> FreeSqlBuilder 上使用 UseGenerateCommandParameterWithLambda(true) 开启 > FreeSqlBuilder 上使用 UseGenerateCommandParameterWithLambda(true) 开启
- 优化 ExpressionCallContext 可设置、附加参数化对象; - 优化 ExpressionCallContext 可设置、附加参数化对象;
- 修复 IncludeMany(a => a.x1.x2.Childs) 当 x1, x2 为 null 的报 null 错误; - 修复 IncludeMany(a => a.x1.x2.Childs) 当 x1, x2 为 null 的报 null 错误;
@@ -423,7 +423,7 @@ po
## v0.11.23 ## v0.11.23
- **增加 ExpressionCallAttribute 特性,实现表达式函数自定义解析;**[wiki](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%E8%87%AA%E5%AE%9A%E4%B9%89%E8%A7%A3%E6%9E%90) - **增加 ExpressionCallAttribute 特性,实现表达式函数自定义解析;**[wiki](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0#%E8%87%AA%E5%AE%9A%E4%B9%89%E8%A7%A3%E6%9E%90)
- 优化 Contains 表达式解析为 where in 自动拆分,防止大于 1000 的 SQL 错误,如下: - 优化 Contains 表达式解析为 where in 自动拆分,防止大于 1000 的 SQL 错误,如下:
```csharp ```csharp
var arr = Enumerable.Range(1, 1333).ToArray(); var arr = Enumerable.Range(1, 1333).ToArray();
@@ -436,7 +436,7 @@ var sql = fsql.Select<T>().Where(a => arr.Contains(a.Int)).ToList();
## v0.11.22 ## v0.11.22
- **兼容 SqlServer nvarchar/varchar 表达式解析分别解析为N'' 和 '',优化索引执行计划;** - **兼容 SqlServer nvarchar/varchar 表达式解析分别解析为N'' 和 '',优化索引执行计划;**
- **增加 MySql 特有功能 Insert Ignore Into**[wiki](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0#mysql-%E7%89%B9%E6%9C%89%E5%8A%9F%E8%83%BD-insert-ignore-into) - **增加 MySql 特有功能 Insert Ignore Into**[wiki](%e6%b7%bb%e5%8a%a0#mysql-%E7%89%B9%E6%9C%89%E5%8A%9F%E8%83%BD-insert-ignore-into)
## v0.11.21 ## v0.11.21
@@ -461,7 +461,7 @@ var sql = fsql.Select<T>().Where(a => arr.Contains(a.Int)).ToList();
## v0.11.18 ## v0.11.18
- 增加 DbContext、Repository SaveManyToMany 方法,实现手工保存 ManyToMany 关联数据;[wiki](https://github.com/2881099/FreeSql/wiki/%e8%81%94%e7%ba%a7%e4%bf%9d%e5%ad%98#savemanytomany) - 增加 DbContext、Repository SaveManyToMany 方法,实现手工保存 ManyToMany 关联数据;[wiki](%e8%81%94%e7%ba%a7%e4%bf%9d%e5%ad%98#savemanytomany)
- 修复 BaseRepository 析构时与工作单元的回滚逻辑 bug#131 - 修复 BaseRepository 析构时与工作单元的回滚逻辑 bug#131
- 优化 ManyToMany 中间表不需要指明 [Column(IsPrimary = true)] 特性; - 优化 ManyToMany 中间表不需要指明 [Column(IsPrimary = true)] 特性;
@@ -473,12 +473,12 @@ var sql = fsql.Select<T>().Where(a => arr.Contains(a.Int)).ToList();
fsql.CodeFirst.SyncStructure(typeof(Log), "Log_1"); //迁移到 Log_1 表 fsql.CodeFirst.SyncStructure(typeof(Log), "Log_1"); //迁移到 Log_1 表
fsql.CodeFirst.SyncStructure(typeof(Log), "Log_2"); //迁移到 Log_2 表 fsql.CodeFirst.SyncStructure(typeof(Log), "Log_2"); //迁移到 Log_2 表
``` ```
- 增加 PostgreSQL 特有功能 On Conflict Do Update 功能,[wiki](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) - 增加 PostgreSQL 特有功能 On Conflict Do Update 功能,[wiki](%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9)
- 完善 所有参数化 object parms 可使用 IDictionary 类型传入; - 完善 所有参数化 object parms 可使用 IDictionary 类型传入;
## v0.11.11 ## v0.11.11
- 增加 MySql 特有功能 On Duplicate Key Update 功能,[wiki](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) - 增加 MySql 特有功能 On Duplicate Key Update 功能,[wiki](%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9)
- 优化 实体类重写属性 new 如果类型与基类不一致,无法使用的问题; - 优化 实体类重写属性 new 如果类型与基类不一致,无法使用的问题;
- 修复 ISelect .From 方法之前使用 .Include 方法,导致生成的多表 JOIN 位置错误的 bug - 修复 ISelect .From 方法之前使用 .Include 方法,导致生成的多表 JOIN 位置错误的 bug
@@ -503,7 +503,7 @@ fsql.CodeFirst.SyncStructure(typeof(Log), "Log_2"); //迁移到 Log_2 表
## v0.11.4 ## v0.11.4
- 增加 ISelect ToDelete/ToUpdate 方法,实现更复杂的删除/更新操作,[wiki](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4#iselecttodelete-%E9%AB%98%E7%BA%A7%E5%88%A0%E9%99%A4) - 增加 ISelect ToDelete/ToUpdate 方法,实现更复杂的删除/更新操作,[wiki](%e5%88%a0%e9%99%a4#iselecttodelete-%E9%AB%98%E7%BA%A7%E5%88%A0%E9%99%A4)
- 移除 IUpdate/IDelete WhereExists 方法; - 移除 IUpdate/IDelete WhereExists 方法;
## v0.11.3 ## v0.11.3
@@ -513,7 +513,7 @@ fsql.CodeFirst.SyncStructure(typeof(Log), "Log_2"); //迁移到 Log_2 表
## v0.11.2 ## v0.11.2
- 增加 IFreeSql.GlobalFilter 全局过滤器,[wiki](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - 增加 IFreeSql.GlobalFilter 全局过滤器,[wiki](%e8%bf%87%e6%bb%a4%e5%99%a8)
- 移除 TableAttribute.SelectFilter 功能; - 移除 TableAttribute.SelectFilter 功能;
- 修复 MySql/SqlServer CodeFirst 同步结构 bug - 修复 MySql/SqlServer CodeFirst 同步结构 bug
> 当表已存在后增加自增列时,产生的脚本不应该包含默认认设置 > 当表已存在后增加自增列时,产生的脚本不应该包含默认认设置
@@ -541,7 +541,7 @@ fsql.CodeFirst.SyncStructure(typeof(Log), "Log_2"); //迁移到 Log_2 表
## v0.10.12 ## v0.10.12
- 增加 FreeSql.DbContext 实体对象的变化事件; - 增加 FreeSql.DbContext 实体对象的变化事件;
> 文档:https://github.com/2881099/FreeSql/wiki/DbContext#%E5%AE%9E%E4%BD%93%E5%8F%98%E5%8C%96%E4%BA%8B%E4%BB%B6 > 文档DbContext#%E5%AE%9E%E4%BD%93%E5%8F%98%E5%8C%96%E4%BA%8B%E4%BB%B6
- 补充 Aop.CurdBefore 事件参数 Table 实体类型的元数据; - 补充 Aop.CurdBefore 事件参数 Table 实体类型的元数据;
## v0.10.11 ## v0.10.11
@@ -562,7 +562,7 @@ fsql.CodeFirst.SyncStructure(typeof(Log), "Log_2"); //迁移到 Log_2 表
- 增加 List\<T1\> 扩展方法 IncludeMany实现从已知的内存 List 数据,进行和 ISelect.IncludeMany 相同功能的贪婪加载; - 增加 List\<T1\> 扩展方法 IncludeMany实现从已知的内存 List 数据,进行和 ISelect.IncludeMany 相同功能的贪婪加载;
> 示例new List\<Song\>(new[] { song1, song2, song3 }).IncludeMany(g.sqlite, a => a.Tags); > 示例new List\<Song\>(new[] { song1, song2, song3 }).IncludeMany(g.sqlite, a => a.Tags);
> 文档:https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd#%E5%AF%BC%E8%88%AA%E5%B1%9E%E6%80%A7-onetomanymanytomany > 文档:%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd#%E5%AF%BC%E8%88%AA%E5%B1%9E%E6%80%A7-onetomanymanytomany
- 修复 FreeSql.DbContext/FreeSql.Repository 当主键为 Guid? 可空类型时,发生参数错误; - 修复 FreeSql.DbContext/FreeSql.Repository 当主键为 Guid? 可空类型时,发生参数错误;
> System.ArgumentException:“Expression of type 'System.Guid' cannot be used for assignment to type 'System.Nullable`1[System.Guid]'” > System.ArgumentException:“Expression of type 'System.Guid' cannot be used for assignment to type 'System.Nullable`1[System.Guid]'”
@@ -579,7 +579,7 @@ fsql.CodeFirst.SyncStructure(typeof(Log), "Log_2"); //迁移到 Log_2 表
## v0.10.5 ## v0.10.5
- 增加 DbContext/Repository ManyToMany联级保存功能之前已支持OneToMany - 增加 DbContext/Repository ManyToMany联级保存功能之前已支持OneToMany
> wiki: https://github.com/2881099/FreeSql/wiki/%e8%81%94%e7%ba%a7%e4%bf%9d%e5%ad%98 > wiki: %e8%81%94%e7%ba%a7%e4%bf%9d%e5%ad%98
## v0.10.4 ## v0.10.4
@@ -708,7 +708,7 @@ class Topic {
## v0.8.11 ## v0.8.11
- 增加 Aop.AuditValue 事件,在插入/更新数据时审计属性值,[wiki](https://github.com/2881099/FreeSql/wiki/AOP) - 增加 Aop.AuditValue 事件,在插入/更新数据时审计属性值,[wiki](AOP)
## v0.8.10 ## v0.8.10
@@ -774,7 +774,7 @@ class Topic {
## v0.7.13 ## v0.7.13
- 增加 ISelect.WhereCascade 实现多表查询时,向每个表中附加条件; [wiki](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2#12wherecascade) - 增加 ISelect.WhereCascade 实现多表查询时,向每个表中附加条件; [wiki](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2#12wherecascade)
- 增加 表达式对基类转换的解析Where(a => (a as BaseEntity).IsDeleted == true) - 增加 表达式对基类转换的解析Where(a => (a as BaseEntity).IsDeleted == true)
- 增加 Examples 项目 base_entity利用 BaseEntity 实现简洁的数据库操作; - 增加 Examples 项目 base_entity利用 BaseEntity 实现简洁的数据库操作;
@@ -793,7 +793,7 @@ class Topic {
## v0.7.8 ## v0.7.8
- 增加 子查询函数 First、Count、Min、Max、Sum、Avg 的支持 [#wiki](https://github.com/2881099/FreeSql/wiki/%E5%A4%9A%E8%A1%A8%E6%9F%A5%E8%AF%A2#8%E5%AD%90%E8%A1%A8-exists) - 增加 子查询函数 First、Count、Min、Max、Sum、Avg 的支持 [#wiki](%E5%A4%9A%E8%A1%A8%E6%9F%A5%E8%AF%A2#8%E5%AD%90%E8%A1%A8-exists)
- 补充 Oracle DbFirst raw 等类型映射处理,其他未处理的类型将映射为 string - 补充 Oracle DbFirst raw 等类型映射处理,其他未处理的类型将映射为 string
## v0.7.6 ## v0.7.6
@@ -911,7 +911,7 @@ class Topic {
- 修复 Include 延时加载 ManyToOne/OneToOne当值为 null 时,仍然会查询一次数据; - 修复 Include 延时加载 ManyToOne/OneToOne当值为 null 时,仍然会查询一次数据;
- 修改 Query/ToList 混合使用时,可能导致的 ET 缓存 bug - 修改 Query/ToList 混合使用时,可能导致的 ET 缓存 bug
- 修改 Query 查询的实体设置了 IsIgnore 时,可能出现 ET 读取位置偏移 bug - 修改 Query 查询的实体设置了 IsIgnore 时,可能出现 ET 读取位置偏移 bug
- 增加 变异的 IncludeMany即使不是导航属性也可以贪婪加载[Wiki](https://github.com/2881099/FreeSql/wiki/%E8%B4%AA%E5%A9%AA%E5%8A%A0%E8%BD%BD#%E5%8F%98%E5%BC%82) - 增加 变异的 IncludeMany即使不是导航属性也可以贪婪加载[Wiki](%E8%B4%AA%E5%A9%AA%E5%8A%A0%E8%BD%BD#%E5%8F%98%E5%BC%82)
## v0.5.12 ## v0.5.12
@@ -922,7 +922,7 @@ class Topic {
## v0.5.11 ## v0.5.11
- 修复 复杂的表达式解析 OR 的括号 bug - 修复 复杂的表达式解析 OR 的括号 bug
- 增加 linq to sql 的查询语法,以及单元测试,[wiki](https://github.com/2881099/FreeSql/wiki/LinqToSql) - 增加 linq to sql 的查询语法,以及单元测试,[wiki](LinqToSql)
- 补充 IFreeSql 增加与实现 IDisposable 接口(依然要保持单例的使用习惯); - 补充 IFreeSql 增加与实现 IDisposable 接口(依然要保持单例的使用习惯);
- 增加 CurdBefore、CurdAfter AOP 事件,可监控执行增删查改; - 增加 CurdBefore、CurdAfter AOP 事件,可监控执行增删查改;
- 增加 SyncStructureBefore、SyncStructureAfter AOP 事件可监控CodeFirst迁移 - 增加 SyncStructureBefore、SyncStructureAfter AOP 事件可监控CodeFirst迁移
@@ -1029,7 +1029,7 @@ class Topic {
## v0.3.27 ## v0.3.27
- 增加 乐观锁功能,适用修改实体,[参考资料](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) - 增加 乐观锁功能,适用修改实体,[参考资料](%e4%bf%ae%e6%94%b9)
- 增加 FreeSql.Repository 默认依赖注入的方式,同时保留原有 Autofac - 增加 FreeSql.Repository 默认依赖注入的方式,同时保留原有 Autofac
- 优化 FreeSql.Repository Insert 逻辑,参考了 FreeSql.DbContext - 优化 FreeSql.Repository Insert 逻辑,参考了 FreeSql.DbContext
- 优化 FreeSql.IUpdate 参照 IInsert 对大批量更新,拆分执行; - 优化 FreeSql.IUpdate 参照 IInsert 对大批量更新,拆分执行;
@@ -1101,7 +1101,7 @@ class Topic {
- 修复 IInsert/IUpdate.NoneParameter() 设成了反作用的 bug - 修复 IInsert/IUpdate.NoneParameter() 设成了反作用的 bug
- 修复 IDbFirst.GetTablesByDatabase 默认数据库 bool 判断 bug - 修复 IDbFirst.GetTablesByDatabase 默认数据库 bool 判断 bug
- 增加 FreeSql.Repository 之 IUnitOfWork 实现,[查看参数资料](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) - 增加 FreeSql.Repository 之 IUnitOfWork 实现,[查看参数资料](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83)
- 增加 FreeSql.Repository 继承实现的仓储注入; - 增加 FreeSql.Repository 继承实现的仓储注入;
```csharp ```csharp
builder.RegisterFreeRepository( builder.RegisterFreeRepository(

@@ -1,20 +1,20 @@
FreeSql在查询数据下足了功夫链式查询语法、多表查询、表达式函数支持得非常到位。 FreeSql在查询数据下足了功夫链式查询语法、多表查询、表达式函数支持得非常到位。
- [《分页查询》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e9%a1%b5%e6%9f%a5%e8%af%a2) - [《分页查询》](%e5%88%86%e9%a1%b5%e6%9f%a5%e8%af%a2)
- [《单表查询》](https://github.com/2881099/FreeSql/wiki/%e5%8d%95%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《单表查询》](%e5%8d%95%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《多表查询》](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《多表查询》](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《分组聚合查询》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e7%bb%84%e8%81%9a%e5%90%88%e6%9f%a5%e8%af%a2) - [《分组聚合查询》](%e5%88%86%e7%bb%84%e8%81%9a%e5%90%88%e6%9f%a5%e8%af%a2)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《LinqToSql》](https://github.com/2881099/FreeSql/wiki/LinqToSql) - [《LinqToSql》](LinqToSql)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
- [《读写分离》](https://github.com/2881099/FreeSql/wiki/%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb) - [《读写分离》](%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
## 特别介绍 WhereDynamicFilter ## 特别介绍 WhereDynamicFilter

@@ -36,7 +36,7 @@ fsql.Select<Area>().Where(a => a.Parent.Parent.Parent.Name == "中国").First();
fsql.Select<Area>().Where(a => a.Childs.AsSelect().Any(c => c.Name == "北京")).First(); fsql.Select<Area>().Where(a => a.Childs.AsSelect().Any(c => c.Name == "北京")).First();
``` ```
定义 Childs 属性,还可以使用[【级联保存】](https://github.com/dotnetcore/FreeSql/wiki/%E8%81%94%E7%BA%A7%E4%BF%9D%E5%AD%98)、[【贪婪加载】](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) 等等操作。 定义 Childs 属性,还可以使用[【级联保存】](%E8%81%94%E7%BA%A7%E4%BF%9D%E5%AD%98)、[【贪婪加载】](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) 等等操作。
```csharp ```csharp
fsql.Delete<Area>().Where("1=1").ExecuteAffrows(); fsql.Delete<Area>().Where("1=1").ExecuteAffrows();
@@ -207,14 +207,14 @@ Assert.Equal("中国[100000] -> 北京[110000] -> 东城区[110101]", t4[3].path
## 参考资料 ## 参考资料
- [《多表查询》](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《多表查询》](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《LinqToSql》](https://github.com/2881099/FreeSql/wiki/LinqToSql) - [《LinqToSql》](LinqToSql)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)

@@ -182,22 +182,22 @@ fsql.Insert<Topic>().MySqlIgnoreInto().AppendData(items).ExecuteAffrows();
## 9、MySql 特有功能 On Duplicate Key Update ## 9、MySql 特有功能 On Duplicate Key Update
[请移步查看详情](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9#mysql-%E7%89%B9%E6%9C%89%E5%8A%9F%E8%83%BD-on-duplicate-key-update) [请移步查看详情](%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9#mysql-%E7%89%B9%E6%9C%89%E5%8A%9F%E8%83%BD-on-duplicate-key-update)
## 10、PostgreSQL 特有功能 On Conflict Do Update ## 10、PostgreSQL 特有功能 On Conflict Do Update
[请移步查看详情](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9#postgresql-%E7%89%B9%E6%9C%89%E5%8A%9F%E8%83%BD-on-conflict-do-update) [请移步查看详情](%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9#postgresql-%E7%89%B9%E6%9C%89%E5%8A%9F%E8%83%BD-on-conflict-do-update)
## 参考资料 ## 参考资料
- [《数据库事务》](https://github.com/2881099/FreeSql/wiki/%e4%ba%8b%e5%8a%a1) - [《数据库事务》](%e4%ba%8b%e5%8a%a1)
- [《学习FreeSql之一删除数据》](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4) - [《学习FreeSql之一删除数据》](%e5%88%a0%e9%99%a4)
- [《学习FreeSql之二修改数据》](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) - [《学习FreeSql之二修改数据》](%e4%bf%ae%e6%94%b9)
- [《学习FreeSql之三查询数据》](https://github.com/2881099/FreeSql/wiki/%e6%9f%a5%e8%af%a2) - [《学习FreeSql之三查询数据》](%e6%9f%a5%e8%af%a2)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
## API ## API
@@ -211,8 +211,8 @@ fsql.Insert<Topic>().MySqlIgnoreInto().AppendData(items).ExecuteAffrows();
| WithTransaction | \<this\> | DbTransaction | 设置事务对象 | | WithTransaction | \<this\> | DbTransaction | 设置事务对象 |
| WithConnection | \<this\> | DbConnection | 设置连接对象 | | WithConnection | \<this\> | DbConnection | 设置连接对象 |
| ToSql | string | | 返回即将执行的SQL语句 | | ToSql | string | | 返回即将执行的SQL语句 |
| [OnDuplicateKeyUpdate](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) | OnDuplicateKeyUpdate\<T1\> | 无 | MySql 特有的功能On Duplicate Key Update | | [OnDuplicateKeyUpdate](%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) | OnDuplicateKeyUpdate\<T1\> | 无 | MySql 特有的功能On Duplicate Key Update |
| [OnConflictDoUpdate](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) | OnConflictDoUpdate\<T1\> | 无 | PostgreSQL 特有的功能On Conflict Do Update | | [OnConflictDoUpdate](%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) | OnConflictDoUpdate\<T1\> | 无 | PostgreSQL 特有的功能On Conflict Do Update |
| ExecuteAffrows | long | | 执行SQL语句返回影响的行数 | | ExecuteAffrows | long | | 执行SQL语句返回影响的行数 |
| ExecuteIdentity | long | | 执行SQL语句返回自增值 | | ExecuteIdentity | long | | 执行SQL语句返回自增值 |
| ExecuteInserted | List\<T1\> | | 执行SQL语句返回插入后的记录 | | ExecuteInserted | List\<T1\> | | 执行SQL语句返回插入后的记录 |

@@ -64,11 +64,11 @@ var reposTopic = orm.GetGuidRepository<Topic>(null, oldname => $"{oldname}{tenan
上面我们得到一个仓储按租户分表,使用它 CURD 最终会操作 Topic_1 表。 上面我们得到一个仓储按租户分表,使用它 CURD 最终会操作 Topic_1 表。
> 更多说明参考:[《FreeSql.Repository 仓储》](https://github.com/2881099/FreeSql/wiki/Repository) > 更多说明参考:[《FreeSql.Repository 仓储》](Repository)
### 方案三:按租户分库 ### 方案三:按租户分库
与方案二相同,只是表存储的位置不同,请查看 [《FreeSql.Repository 仓储》](https://github.com/2881099/FreeSql/wiki/Repository)、[《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)。 与方案二相同,只是表存储的位置不同,请查看 [《FreeSql.Repository 仓储》](Repository)、[《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)。
### 多表查询 ### 多表查询
@@ -95,17 +95,17 @@ LEFT JOIN "TopicType_1" b ON a."TypeId" = b."Id"
FreeSql.Repository Autofac 注入方式实现了全局【过滤与验证】的设定,方便租户功能的设计; FreeSql.Repository Autofac 注入方式实现了全局【过滤与验证】的设定,方便租户功能的设计;
具体可参考:[《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) 具体可参考:[《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
## 参考资料 ## 参考资料
- [《读写分离》](https://github.com/2881099/FreeSql/wiki/%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb) - [《读写分离》](%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《UnitOfWork》](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) - [《UnitOfWork》](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83)
- [《学习FreeSql之一添加数据》](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0) - [《学习FreeSql之一添加数据》](%e6%b7%bb%e5%8a%a0)
- [《学习FreeSql之二删除数据》](https://github.com/2881099/FreeSql/wiki/%e5%88%a0%e9%99%a4) - [《学习FreeSql之二删除数据》](%e5%88%a0%e9%99%a4)
- [《学习FreeSql之三修改数据》](https://github.com/2881099/FreeSql/wiki/%e4%bf%ae%e6%94%b9) - [《学习FreeSql之三修改数据》](%e4%bf%ae%e6%94%b9)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)

@@ -136,14 +136,14 @@ public class S_SysConfig {
## 参考资料 ## 参考资料
- [《实体特性说明》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) - [《实体特性说明》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
- [《FluentApi享受纯净实体类》](https://github.com/2881099/FreeSql/wiki/FluentApi) - [《FluentApi享受纯净实体类》](FluentApi)
- [《导入数据库特性,懒人专利》](https://github.com/2881099/FreeSql/wiki/%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7) - [《导入数据库特性,懒人专利》](%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7)
- [《Aop自定义特性与其他 ORM 共用特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) - [《Aop自定义特性与其他 ORM 共用特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
- [《导航关系配置》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb) - [《导航关系配置》](%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb)
- [《CodeFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/CodeFirst) - [《CodeFirst模式开发介绍》](CodeFirst)

@@ -42,14 +42,14 @@ class MyColumnAttribute : Attribute {
## 参考资料 ## 参考资料
- [《实体特性说明》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) - [《实体特性说明》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
- [《FluentApi享受纯净实体类》](https://github.com/2881099/FreeSql/wiki/FluentApi) - [《FluentApi享受纯净实体类》](FluentApi)
- [《导入数据库特性,懒人专利》](https://github.com/2881099/FreeSql/wiki/%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7) - [《导入数据库特性,懒人专利》](%e5%af%bc%e5%85%a5%e6%95%b0%e6%8d%ae%e5%ba%93%e7%89%b9%e6%80%a7)
- [《类型映射,一览便知》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) - [《类型映射,一览便知》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
- [《导航关系配置》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb) - [《导航关系配置》](%e5%ae%9e%e4%bd%93%e5%85%b3%e7%b3%bb)
- [《CodeFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/CodeFirst) - [《CodeFirst模式开发介绍》](CodeFirst)

@@ -394,11 +394,11 @@ public static class DbFunc {
## 参考资料 ## 参考资料
- [《多表查询》](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《多表查询》](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《LinqToSql》](https://github.com/2881099/FreeSql/wiki/LinqToSql) - [《LinqToSql》](LinqToSql)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)

@@ -30,16 +30,16 @@ fsql.Select<T>().Master().WhereId(a => a.Id == 1).ToOne(); //强制读【主库
## 参考资料 ## 参考资料
- [《数据库事务》](https://github.com/2881099/FreeSql/wiki/%e4%ba%8b%e5%8a%a1) - [《数据库事务》](%e4%ba%8b%e5%8a%a1)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
* [《CodeFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/CodeFirst) * [《CodeFirst模式开发介绍》](CodeFirst)
* [《CodeFirst模式之一实体特性》](https://github.com/2881099/FreeSql/wiki/%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7) * [《CodeFirst模式之一实体特性》](%e5%ae%9e%e4%bd%93%e7%89%b9%e6%80%a7)
* [《CodeFirst模式之二FluentApi》](https://github.com/2881099/FreeSql/wiki/FluentApi) * [《CodeFirst模式之二FluentApi》](FluentApi)
* [《CodeFirst模式之三自定义特性》](https://github.com/2881099/FreeSql/wiki/%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7) * [《CodeFirst模式之三自定义特性》](%e8%87%aa%e5%ae%9a%e4%b9%89%e7%89%b9%e6%80%a7)
* [《CodeFirst模式之四类型映射》](https://github.com/2881099/FreeSql/wiki/%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84) * [《CodeFirst模式之四类型映射》](%e7%b1%bb%e5%9e%8b%e6%98%a0%e5%b0%84)
* [《CodeFirst模式之五迁移结构》](https://github.com/2881099/FreeSql/wiki/CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84) * [《CodeFirst模式之五迁移结构》](CodeFirst#%e8%bf%81%e7%a7%bb%e7%bb%93%e6%9e%84)
- [《DbFirst模式开发介绍》](https://github.com/2881099/FreeSql/wiki/DbFirst) - [《DbFirst模式开发介绍》](DbFirst)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《AOP》](https://github.com/2881099/FreeSql/wiki/AOP) - [《AOP》](AOP)

@@ -127,11 +127,11 @@ dto.IncludeMany(fsql, d => d.Vods.Take(10).Where(vod => vod.TypeId == d.TypeId))
## 参考资料 ## 参考资料
- [《多表查询》](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《多表查询》](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《LinqToSql》](https://github.com/2881099/FreeSql/wiki/LinqToSql) - [《LinqToSql》](LinqToSql)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)

@@ -112,9 +112,9 @@ public void ConfigureServices(IServiceCollection services) {
## 参考资料 ## 参考资料
- [《租户》](%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)
- [《读写分离》](https://github.com/2881099/FreeSql/wiki/%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb) - [《读写分离》](%e8%af%bb%e5%86%99%e5%88%86%e7%a6%bb)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《AOP》](https://github.com/2881099/FreeSql/wiki/AOP) - [《AOP》](AOP)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《UnitOfWork》](https://github.com/2881099/FreeSql/wiki/%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83) - [《UnitOfWork》](%e5%b7%a5%e4%bd%9c%e5%8d%95%e5%85%83)
- [《DbContext》](https://github.com/2881099/FreeSql/wiki/DbContext) - [《DbContext》](DbContext)

@@ -171,14 +171,14 @@ A, B, C 都有 idDto { id, a1, a2, b1, b2 }A.id 被映射。也可以指
## 参考资料 ## 参考资料
- [《多表查询》](https://github.com/2881099/FreeSql/wiki/%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2) - [《多表查询》](%e5%a4%9a%e8%a1%a8%e6%9f%a5%e8%af%a2)
- [《返回数据》](https://github.com/2881099/FreeSql/wiki/%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae) - [《返回数据》](%e8%bf%94%e5%9b%9e%e6%95%b0%e6%8d%ae)
- [《LinqToSql》](https://github.com/2881099/FreeSql/wiki/LinqToSql) - [《LinqToSql》](LinqToSql)
- [《仓储层Repository》](https://github.com/2881099/FreeSql/wiki/Repository) - [《仓储层Repository》](Repository)
- [《过滤器、全局过滤器》](https://github.com/2881099/FreeSql/wiki/%e8%bf%87%e6%bb%a4%e5%99%a8) - [《过滤器、全局过滤器》](%e8%bf%87%e6%bb%a4%e5%99%a8)
- [《优化之:延时加载》](https://github.com/2881099/FreeSql/wiki/%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd) - [《优化之:延时加载》](%e5%bb%b6%e6%97%b6%e5%8a%a0%e8%bd%bd)
- [《优化之:贪婪加载》](https://github.com/2881099/FreeSql/wiki/%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd) - [《优化之:贪婪加载》](%e8%b4%aa%e5%a9%aa%e5%8a%a0%e8%bd%bd)
- [《Expression 表达式函数》](https://github.com/2881099/FreeSql/wiki/%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0) - [《Expression 表达式函数》](%e8%a1%a8%e8%be%be%e5%bc%8f%e5%87%bd%e6%95%b0)
- [《性能》](https://github.com/2881099/FreeSql/wiki/%e6%80%a7%e8%83%bd) - [《性能》](%e6%80%a7%e8%83%bd)
- [《分表、分库》](https://github.com/2881099/FreeSql/wiki/%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93) - [《分表、分库》](%e5%88%86%e8%a1%a8%e5%88%86%e5%ba%93)
- [《租户》](https://github.com/2881099/FreeSql/wiki/%e7%a7%9f%e6%88%b7) - [《租户》](%e7%a7%9f%e6%88%b7)

@@ -33,7 +33,7 @@ var repo = fsql.GetRepository<T>();
repo.InsertOrUpdate(实体); repo.InsertOrUpdate(实体);
``` ```
> 更多资料移步:[wiki](https://github.com/2881099/FreeSql/wiki/%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9) > 更多资料移步:[wiki](%e6%b7%bb%e5%8a%a0%e6%88%96%e4%bf%ae%e6%94%b9)
--- ---