diff --git a/FreeSql.DbContext/FreeSql.DbContext.xml b/FreeSql.DbContext/FreeSql.DbContext.xml index e4208f1f..b3c14870 100644 --- a/FreeSql.DbContext/FreeSql.DbContext.xml +++ b/FreeSql.DbContext/FreeSql.DbContext.xml @@ -502,14 +502,5 @@ - - - 批量注入 Repository,可以参考代码自行调整 - - - - - - diff --git a/FreeSql.Tests/FreeSql.Tests/AppSetting.cs b/FreeSql.Tests/FreeSql.Tests/AppSetting.cs index bd82b2d1..ade54964 100644 --- a/FreeSql.Tests/FreeSql.Tests/AppSetting.cs +++ b/FreeSql.Tests/FreeSql.Tests/AppSetting.cs @@ -917,7 +917,7 @@ namespace AME.Helpers public bool FormMiniWebAppAutoLoadOrderDetails { get => formMiniWebAppAutoLoadOrderDetails; set { if (SetProperty(ref formMiniWebAppAutoLoadOrderDetails, value)) SaveAI(); } } /// - /// 使用会员卡&优惠券窗口自动关闭 + /// 使用会员卡优惠券窗口自动关闭 /// bool formUsingCouponAutoClose = true; [DisplayName("自动关闭")] diff --git a/FreeSql.Tests/FreeSql.Tests/FreeSql.Tests.xml b/FreeSql.Tests/FreeSql.Tests/FreeSql.Tests.xml index 79e53cb8..010c32bc 100644 --- a/FreeSql.Tests/FreeSql.Tests/FreeSql.Tests.xml +++ b/FreeSql.Tests/FreeSql.Tests/FreeSql.Tests.xml @@ -762,7 +762,11 @@ 小程序单据自动调入详单 - + + + 使用会员卡优惠券窗口自动关闭 + + 提醒非正常商品状态 diff --git a/FreeSql/FreeSql.xml b/FreeSql/FreeSql.xml index 5140edee..f5d2d1db 100644 --- a/FreeSql/FreeSql.xml +++ b/FreeSql/FreeSql.xml @@ -1362,7 +1362,7 @@ - 原生sql语法条件,Where("id = ?id", new { id = 1 }) + 原生sql语法条件,Where("id = @id", new { id = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> sql语法条件 @@ -1904,7 +1904,7 @@ - 左联查询,使用原生sql语法,LeftJoin("type b on b.id = a.id and b.clicks > ?clicks", new { clicks = 1 }) + 左联查询,使用原生sql语法,LeftJoin("type b on b.id = a.id and b.clicks > @clicks", new { clicks = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> sql语法条件 @@ -1913,7 +1913,7 @@ - 联接查询,使用原生sql语法,InnerJoin("type b on b.id = a.id and b.clicks > ?clicks", new { clicks = 1 }) + 联接查询,使用原生sql语法,InnerJoin("type b on b.id = a.id and b.clicks > @clicks", new { clicks = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> sql语法条件 @@ -1922,7 +1922,7 @@ - 右联查询,使用原生sql语法,RightJoin("type b on b.id = a.id and b.clicks > ?clicks", new { clicks = 1 }) + 右联查询,使用原生sql语法,RightJoin("type b on b.id = a.id and b.clicks > @clicks", new { clicks = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> sql语法条件 @@ -1939,7 +1939,7 @@ - 原生sql语法条件,Where("id = ?id", new { id = 1 }) + 原生sql语法条件,Where("id = @id", new { id = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> sql语法条件 @@ -1948,7 +1948,7 @@ - 原生sql语法条件,WhereIf(true, "id = ?id", new { id = 1 }) + 原生sql语法条件,WhereIf(true, "id = @id", new { id = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> true 时生效 @@ -1988,7 +1988,7 @@ - 按原生sql语法分组,GroupBy("concat(name, ?cc)", new { cc = 1 }) + 按原生sql语法分组,GroupBy("concat(name, @cc)", new { cc = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> sql语法 @@ -1997,7 +1997,7 @@ - 按原生sql语法聚合条件过滤,Having("count(name) = ?cc", new { cc = 1 }) + 按原生sql语法聚合条件过滤,Having("count(name) = @cc", new { cc = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> sql语法条件 @@ -2006,7 +2006,7 @@ - 按原生sql语法排序,OrderBy("count(name) + ?cc desc", new { cc = 1 }) + 按原生sql语法排序,OrderBy("count(name) + @cc desc", new { cc = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> sql语法 @@ -2015,7 +2015,7 @@ - 按原生sql语法排序,OrderBy(true, "count(name) + ?cc desc", new { cc = 1 }) + 按原生sql语法排序,OrderBy(true, "count(name) + @cc desc", new { cc = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> true 时生效 @@ -2425,7 +2425,7 @@ 实现 select .. from ( select ... from t ) a 这样的功能 使用 AsTable 方法也可以达到效果 - 示例:WithSql("select * from id=?id", new { id = 1 }) + 示例:WithSql("select * from id=@id", new { id = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> SQL语句 @@ -2760,7 +2760,7 @@ - 设置值,自定义SQL语法,SetRaw("title = ?title", new { title = "newtitle" }) + 设置值,自定义SQL语法,SetRaw("title = @title", new { title = "newtitle" }) 提示:parms 参数还可以传 Dictionary<string, object> sql语法 @@ -2796,7 +2796,7 @@ - 原生sql语法条件,Where("id = ?id", new { id = 1 }) + 原生sql语法条件,Where("id = @id", new { id = 1 }) 提示:parms 参数还可以传 Dictionary<string, object> sql语法条件 @@ -2922,7 +2922,7 @@ - SQL 命令执行类,fsql.Ado.CommandFluent("select * from user where age > ?age", new { age = 25 }) + SQL 命令执行类,fsql.Ado.CommandFluent("select * from user where age > @age", new { age = 25 }) .WithConnection(connection) .WithTransaction(transaction) .WithParameter("age", 25) @@ -2955,7 +2955,7 @@ - 查询,ExecuteReader(dr => {}, "select * from user where age > ?age", new { age = 25 }) + 查询,ExecuteReader(dr => {}, "select * from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -2972,7 +2972,7 @@ - 查询,ExecuteArray("select * from user where age > ?age", new { age = 25 }) + 查询,ExecuteArray("select * from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -2989,7 +2989,7 @@ - 查询,ExecuteDataSet("select * from user where age > ?age; select 2", new { age = 25 }) + 查询,ExecuteDataSet("select * from user where age > @age; select 2", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3006,7 +3006,7 @@ - 查询,ExecuteDataTable("select * from user where age > ?age", new { age = 25 }) + 查询,ExecuteDataTable("select * from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3023,7 +3023,7 @@ - 在【主库】执行,ExecuteNonQuery("delete from user where age > ?age", new { age = 25 }) + 在【主库】执行,ExecuteNonQuery("delete from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3040,7 +3040,7 @@ - 在【主库】执行,ExecuteScalar("select 1 from user where age > ?age", new { age = 25 }) + 在【主库】执行,ExecuteScalar("select 1 from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3049,7 +3049,7 @@ - 执行SQL返回对象集合,Query<User>("select * from user where age > ?age", new SqlParameter { ParameterName = "age", Value = 25 }) + 执行SQL返回对象集合,Query<User>("select * from user where age > @age", new SqlParameter { ParameterName = "age", Value = 25 }) @@ -3059,7 +3059,7 @@ - 执行SQL返回对象集合,Query<User>("select * from user where age > ?age", new { age = 25 }) + 执行SQL返回对象集合,Query<User>("select * from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3069,7 +3069,7 @@ - 执行SQL返回对象集合,Query<User>("select * from user where age > ?age; select * from address", new SqlParameter { ParameterName = "age", Value = 25 }) + 执行SQL返回对象集合,Query<User>("select * from user where age > @age; select * from address", new SqlParameter { ParameterName = "age", Value = 25 }) @@ -3080,7 +3080,7 @@ - 执行SQL返回对象集合,Query<User>("select * from user where age > ?age; select * from address", new { age = 25 }) + 执行SQL返回对象集合,Query<User>("select * from user where age > @age; select * from address", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3111,7 +3111,7 @@ - 查询,ExecuteReaderAsync(dr => {}, "select * from user where age > ?age", new { age = 25 }) + 查询,ExecuteReaderAsync(dr => {}, "select * from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3130,7 +3130,7 @@ - 查询,ExecuteArrayAsync("select * from user where age > ?age", new { age = 25 }) + 查询,ExecuteArrayAsync("select * from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3149,7 +3149,7 @@ - 查询,ExecuteDataSetAsync("select * from user where age > ?age; select 2", new { age = 25 }) + 查询,ExecuteDataSetAsync("select * from user where age > @age; select 2", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3168,7 +3168,7 @@ - 查询,ExecuteDataTableAsync("select * from user where age > ?age", new { age = 25 }) + 查询,ExecuteDataTableAsync("select * from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3187,7 +3187,7 @@ - 在【主库】执行,ExecuteNonQueryAsync("delete from user where age > ?age", new { age = 25 }) + 在【主库】执行,ExecuteNonQueryAsync("delete from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3206,7 +3206,7 @@ - 在【主库】执行,ExecuteScalarAsync("select 1 from user where age > ?age", new { age = 25 }) + 在【主库】执行,ExecuteScalarAsync("select 1 from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3216,7 +3216,7 @@ - 执行SQL返回对象集合,QueryAsync<User>("select * from user where age > ?age", new SqlParameter { ParameterName = "age", Value = 25 }) + 执行SQL返回对象集合,QueryAsync<User>("select * from user where age > @age", new SqlParameter { ParameterName = "age", Value = 25 }) @@ -3227,7 +3227,7 @@ - 执行SQL返回对象集合,QueryAsync<User>("select * from user where age > ?age", new { age = 25 }) + 执行SQL返回对象集合,QueryAsync<User>("select * from user where age > @age", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> @@ -3238,7 +3238,7 @@ - 执行SQL返回对象集合,Query<User>("select * from user where age > ?age; select * from address", new SqlParameter { ParameterName = "age", Value = 25 }) + 执行SQL返回对象集合,Query<User>("select * from user where age > @age; select * from address", new SqlParameter { ParameterName = "age", Value = 25 }) @@ -3250,7 +3250,7 @@ - 执行SQL返回对象集合,Query<User, Address>("select * from user where age > ?age; select * from address", new { age = 25 }) + 执行SQL返回对象集合,Query<User, Address>("select * from user where age > @age; select * from address", new { age = 25 }) 提示:parms 参数还可以传 Dictionary<string, object> diff --git a/FreeSql/Interface/Curd/IDelete.cs b/FreeSql/Interface/Curd/IDelete.cs index 7a460d31..7a034789 100644 --- a/FreeSql/Interface/Curd/IDelete.cs +++ b/FreeSql/Interface/Curd/IDelete.cs @@ -45,7 +45,7 @@ namespace FreeSql /// IDelete WhereIf(bool condition, Expression> exp); /// - /// 原生sql语法条件,Where("id = ?id", new { id = 1 }) + /// 原生sql语法条件,Where("id = @id", new { id = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// sql语法条件 diff --git a/FreeSql/Interface/Curd/ISelect/ISelect0.cs b/FreeSql/Interface/Curd/ISelect/ISelect0.cs index 3f0119fc..1ecab564 100644 --- a/FreeSql/Interface/Curd/ISelect/ISelect0.cs +++ b/FreeSql/Interface/Curd/ISelect/ISelect0.cs @@ -238,7 +238,7 @@ namespace FreeSql TSelect RightJoin(Expression> exp); /// - /// 左联查询,使用原生sql语法,LeftJoin("type b on b.id = a.id and b.clicks > ?clicks", new { clicks = 1 }) + /// 左联查询,使用原生sql语法,LeftJoin("type b on b.id = a.id and b.clicks > @clicks", new { clicks = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// sql语法条件 @@ -246,7 +246,7 @@ namespace FreeSql /// TSelect LeftJoin(string sql, object parms = null); /// - /// 联接查询,使用原生sql语法,InnerJoin("type b on b.id = a.id and b.clicks > ?clicks", new { clicks = 1 }) + /// 联接查询,使用原生sql语法,InnerJoin("type b on b.id = a.id and b.clicks > @clicks", new { clicks = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// sql语法条件 @@ -254,7 +254,7 @@ namespace FreeSql /// TSelect InnerJoin(string sql, object parms = null); /// - /// 右联查询,使用原生sql语法,RightJoin("type b on b.id = a.id and b.clicks > ?clicks", new { clicks = 1 }) + /// 右联查询,使用原生sql语法,RightJoin("type b on b.id = a.id and b.clicks > @clicks", new { clicks = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// sql语法条件 @@ -270,7 +270,7 @@ namespace FreeSql TSelect RawJoin(string sql); /// - /// 原生sql语法条件,Where("id = ?id", new { id = 1 }) + /// 原生sql语法条件,Where("id = @id", new { id = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// sql语法条件 @@ -278,7 +278,7 @@ namespace FreeSql /// TSelect Where(string sql, object parms = null); /// - /// 原生sql语法条件,WhereIf(true, "id = ?id", new { id = 1 }) + /// 原生sql语法条件,WhereIf(true, "id = @id", new { id = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// true 时生效 @@ -318,7 +318,7 @@ namespace FreeSql TSelect ForUpdate(bool nowait = false); /// - /// 按原生sql语法分组,GroupBy("concat(name, ?cc)", new { cc = 1 }) + /// 按原生sql语法分组,GroupBy("concat(name, @cc)", new { cc = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// sql语法 @@ -326,7 +326,7 @@ namespace FreeSql /// TSelect GroupBy(string sql, object parms = null); /// - /// 按原生sql语法聚合条件过滤,Having("count(name) = ?cc", new { cc = 1 }) + /// 按原生sql语法聚合条件过滤,Having("count(name) = @cc", new { cc = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// sql语法条件 @@ -335,7 +335,7 @@ namespace FreeSql TSelect Having(string sql, object parms = null); /// - /// 按原生sql语法排序,OrderBy("count(name) + ?cc desc", new { cc = 1 }) + /// 按原生sql语法排序,OrderBy("count(name) + @cc desc", new { cc = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// sql语法 @@ -343,7 +343,7 @@ namespace FreeSql /// TSelect OrderBy(string sql, object parms = null); /// - /// 按原生sql语法排序,OrderBy(true, "count(name) + ?cc desc", new { cc = 1 }) + /// 按原生sql语法排序,OrderBy(true, "count(name) + @cc desc", new { cc = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// true 时生效 diff --git a/FreeSql/Interface/Curd/ISelect/ISelect1.cs b/FreeSql/Interface/Curd/ISelect/ISelect1.cs index d2537fcb..5a483835 100644 --- a/FreeSql/Interface/Curd/ISelect/ISelect1.cs +++ b/FreeSql/Interface/Curd/ISelect/ISelect1.cs @@ -360,7 +360,7 @@ namespace FreeSql /// /// 实现 select .. from ( select ... from t ) a 这样的功能 /// 使用 AsTable 方法也可以达到效果 - /// 示例:WithSql("select * from id=?id", new { id = 1 }) + /// 示例:WithSql("select * from id=@id", new { id = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// SQL语句 diff --git a/FreeSql/Interface/Curd/ISelect/ISelect2`16.cs b/FreeSql/Interface/Curd/ISelect/ISelect2`16.cs index b619f156..4cd64f36 100644 --- a/FreeSql/Interface/Curd/ISelect/ISelect2`16.cs +++ b/FreeSql/Interface/Curd/ISelect/ISelect2`16.cs @@ -1,5 +1,4 @@ - -using FreeSql.Internal.Model; +using FreeSql.Internal.Model; using System; using System.Collections.Generic; using System.Data; @@ -10,13 +9,6 @@ using System.Threading.Tasks; namespace FreeSql { - - - - - - - public interface ISelect : ISelect0, T1> where T2 : class { diff --git a/FreeSql/Interface/Curd/IUpdate.cs b/FreeSql/Interface/Curd/IUpdate.cs index 87a372f7..f18eeb3b 100644 --- a/FreeSql/Interface/Curd/IUpdate.cs +++ b/FreeSql/Interface/Curd/IUpdate.cs @@ -151,7 +151,7 @@ namespace FreeSql /// IUpdate SetIf(bool condition, Expression> exp); /// - /// 设置值,自定义SQL语法,SetRaw("title = ?title", new { title = "newtitle" }) + /// 设置值,自定义SQL语法,SetRaw("title = @title", new { title = "newtitle" }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// sql语法 @@ -185,7 +185,7 @@ namespace FreeSql /// IUpdate WhereIf(bool condition, Expression> exp); /// - /// 原生sql语法条件,Where("id = ?id", new { id = 1 }) + /// 原生sql语法条件,Where("id = @id", new { id = 1 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// sql语法条件 diff --git a/FreeSql/Interface/IAdo.cs b/FreeSql/Interface/IAdo.cs index de93f269..41a6a708 100644 --- a/FreeSql/Interface/IAdo.cs +++ b/FreeSql/Interface/IAdo.cs @@ -64,7 +64,7 @@ namespace FreeSql DbParameter[] GetDbParamtersByObject(object obj); /// - /// SQL 命令执行类,fsql.Ado.CommandFluent("select * from user where age > ?age", new { age = 25 }) + /// SQL 命令执行类,fsql.Ado.CommandFluent("select * from user where age > @age", new { age = 25 }) /// .WithConnection(connection) /// .WithTransaction(transaction) /// .WithParameter("age", 25) @@ -98,7 +98,7 @@ namespace FreeSql void ExecuteReader(DbTransaction transaction, Action> fetchHandler, CommandType cmdType, string cmdText, params DbParameter[] cmdParms); void ExecuteReader(DbConnection connection, DbTransaction transaction, Action> fetchHandler, CommandType cmdType, string cmdText, int cmdTimeout, params DbParameter[] cmdParms); /// - /// 查询,ExecuteReader(dr => {}, "select * from user where age > ?age", new { age = 25 }) + /// 查询,ExecuteReader(dr => {}, "select * from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -117,7 +117,7 @@ namespace FreeSql object[][] ExecuteArray(DbTransaction transaction, CommandType cmdType, string cmdText, params DbParameter[] cmdParms); object[][] ExecuteArray(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, params DbParameter[] cmdParms); /// - /// 查询,ExecuteArray("select * from user where age > ?age", new { age = 25 }) + /// 查询,ExecuteArray("select * from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -136,7 +136,7 @@ namespace FreeSql DataSet ExecuteDataSet(DbTransaction transaction, CommandType cmdType, string cmdText, params DbParameter[] cmdParms); DataSet ExecuteDataSet(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, params DbParameter[] cmdParms); /// - /// 查询,ExecuteDataSet("select * from user where age > ?age; select 2", new { age = 25 }) + /// 查询,ExecuteDataSet("select * from user where age > @age; select 2", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -155,7 +155,7 @@ namespace FreeSql DataTable ExecuteDataTable(DbTransaction transaction, CommandType cmdType, string cmdText, params DbParameter[] cmdParms); DataTable ExecuteDataTable(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, params DbParameter[] cmdParms); /// - /// 查询,ExecuteDataTable("select * from user where age > ?age", new { age = 25 }) + /// 查询,ExecuteDataTable("select * from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -174,7 +174,7 @@ namespace FreeSql int ExecuteNonQuery(DbTransaction transaction, CommandType cmdType, string cmdText, params DbParameter[] cmdParms); int ExecuteNonQuery(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, params DbParameter[] cmdParms); /// - /// 在【主库】执行,ExecuteNonQuery("delete from user where age > ?age", new { age = 25 }) + /// 在【主库】执行,ExecuteNonQuery("delete from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -193,7 +193,7 @@ namespace FreeSql object ExecuteScalar(DbTransaction transaction, CommandType cmdType, string cmdText, params DbParameter[] cmdParms); object ExecuteScalar(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, params DbParameter[] cmdParms); /// - /// 在【主库】执行,ExecuteScalar("select 1 from user where age > ?age", new { age = 25 }) + /// 在【主库】执行,ExecuteScalar("select 1 from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -204,7 +204,7 @@ namespace FreeSql object ExecuteScalar(DbConnection connection, DbTransaction transaction, string cmdText, object parms = null); /// - /// 执行SQL返回对象集合,Query<User>("select * from user where age > ?age", new SqlParameter { ParameterName = "age", Value = 25 }) + /// 执行SQL返回对象集合,Query<User>("select * from user where age > @age", new SqlParameter { ParameterName = "age", Value = 25 }) /// /// /// @@ -217,7 +217,7 @@ namespace FreeSql List Query(Type resultType, DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, params DbParameter[] cmdParms); T QuerySingle(CommandType cmdType, string cmdText, params DbParameter[] cmdParms); /// - /// 执行SQL返回对象集合,Query<User>("select * from user where age > ?age", new { age = 25 }) + /// 执行SQL返回对象集合,Query<User>("select * from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -230,7 +230,7 @@ namespace FreeSql T QuerySingle(string cmdText, object parms = null); /// - /// 执行SQL返回对象集合,Query<User>("select * from user where age > ?age; select * from address", new SqlParameter { ParameterName = "age", Value = 25 }) + /// 执行SQL返回对象集合,Query<User>("select * from user where age > @age; select * from address", new SqlParameter { ParameterName = "age", Value = 25 }) /// /// /// @@ -242,7 +242,7 @@ namespace FreeSql NativeTuple, List> Query(DbTransaction transaction, CommandType cmdType, string cmdText, params DbParameter[] cmdParms); NativeTuple, List> Query(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, params DbParameter[] cmdParms); /// - /// 执行SQL返回对象集合,Query<User>("select * from user where age > ?age; select * from address", new { age = 25 }) + /// 执行SQL返回对象集合,Query<User>("select * from user where age > @age; select * from address", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -298,7 +298,7 @@ namespace FreeSql Task ExecuteReaderAsync(DbTransaction transaction, Func, Task> readerHander, CommandType cmdType, string cmdText, DbParameter[] cmdParms, CancellationToken cancellationToken = default); Task ExecuteReaderAsync(DbConnection connection, DbTransaction transaction, Func, Task> readerHander, CommandType cmdType, string cmdText, int cmdTimeout, DbParameter[] cmdParms, CancellationToken cancellationToken = default); /// - /// 查询,ExecuteReaderAsync(dr => {}, "select * from user where age > ?age", new { age = 25 }) + /// 查询,ExecuteReaderAsync(dr => {}, "select * from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -319,7 +319,7 @@ namespace FreeSql Task ExecuteArrayAsync(DbTransaction transaction, CommandType cmdType, string cmdText, DbParameter[] cmdParms, CancellationToken cancellationToken = default); Task ExecuteArrayAsync(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, DbParameter[] cmdParms, CancellationToken cancellationToken = default); /// - /// 查询,ExecuteArrayAsync("select * from user where age > ?age", new { age = 25 }) + /// 查询,ExecuteArrayAsync("select * from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -340,7 +340,7 @@ namespace FreeSql Task ExecuteDataSetAsync(DbTransaction transaction, CommandType cmdType, string cmdText, DbParameter[] cmdParms, CancellationToken cancellationToken = default); Task ExecuteDataSetAsync(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, DbParameter[] cmdParms, CancellationToken cancellationToken = default); /// - /// 查询,ExecuteDataSetAsync("select * from user where age > ?age; select 2", new { age = 25 }) + /// 查询,ExecuteDataSetAsync("select * from user where age > @age; select 2", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -361,7 +361,7 @@ namespace FreeSql Task ExecuteDataTableAsync(DbTransaction transaction, CommandType cmdType, string cmdText, DbParameter[] cmdParms, CancellationToken cancellationToken = default); Task ExecuteDataTableAsync(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, DbParameter[] cmdParms, CancellationToken cancellationToken = default); /// - /// 查询,ExecuteDataTableAsync("select * from user where age > ?age", new { age = 25 }) + /// 查询,ExecuteDataTableAsync("select * from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -382,7 +382,7 @@ namespace FreeSql Task ExecuteNonQueryAsync(DbTransaction transaction, CommandType cmdType, string cmdText, DbParameter[] cmdParms, CancellationToken cancellationToken = default); Task ExecuteNonQueryAsync(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, DbParameter[] cmdParms, CancellationToken cancellationToken = default); /// - /// 在【主库】执行,ExecuteNonQueryAsync("delete from user where age > ?age", new { age = 25 }) + /// 在【主库】执行,ExecuteNonQueryAsync("delete from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -403,7 +403,7 @@ namespace FreeSql Task ExecuteScalarAsync(DbTransaction transaction, CommandType cmdType, string cmdText, DbParameter[] cmdParms, CancellationToken cancellationToken = default); Task ExecuteScalarAsync(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, DbParameter[] cmdParms, CancellationToken cancellationToken = default); /// - /// 在【主库】执行,ExecuteScalarAsync("select 1 from user where age > ?age", new { age = 25 }) + /// 在【主库】执行,ExecuteScalarAsync("select 1 from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -415,7 +415,7 @@ namespace FreeSql Task ExecuteScalarAsync(DbConnection connection, DbTransaction transaction, string cmdText, object parms = null, CancellationToken cancellationToken = default); /// - /// 执行SQL返回对象集合,QueryAsync<User>("select * from user where age > ?age", new SqlParameter { ParameterName = "age", Value = 25 }) + /// 执行SQL返回对象集合,QueryAsync<User>("select * from user where age > @age", new SqlParameter { ParameterName = "age", Value = 25 }) /// /// /// @@ -429,7 +429,7 @@ namespace FreeSql Task> QueryAsync(Type resultType, DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, DbParameter[] cmdParms, CancellationToken cancellationToken = default); Task QuerySingleAsync(string cmdText, object parms = null, CancellationToken cancellationToken = default); /// - /// 执行SQL返回对象集合,QueryAsync<User>("select * from user where age > ?age", new { age = 25 }) + /// 执行SQL返回对象集合,QueryAsync<User>("select * from user where age > @age", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// @@ -443,7 +443,7 @@ namespace FreeSql Task QuerySingleAsync(CommandType cmdType, string cmdText, DbParameter[] cmdParms, CancellationToken cancellationToken = default); /// - /// 执行SQL返回对象集合,Query<User>("select * from user where age > ?age; select * from address", new SqlParameter { ParameterName = "age", Value = 25 }) + /// 执行SQL返回对象集合,Query<User>("select * from user where age > @age; select * from address", new SqlParameter { ParameterName = "age", Value = 25 }) /// /// /// @@ -456,7 +456,7 @@ namespace FreeSql Task, List>> QueryAsync(DbTransaction transaction, CommandType cmdType, string cmdText, DbParameter[] cmdParms, CancellationToken cancellationToken = default); Task, List>> QueryAsync(DbConnection connection, DbTransaction transaction, CommandType cmdType, string cmdText, int cmdTimeout, DbParameter[] cmdParms, CancellationToken cancellationToken = default); /// - /// 执行SQL返回对象集合,Query<User, Address>("select * from user where age > ?age; select * from address", new { age = 25 }) + /// 执行SQL返回对象集合,Query<User, Address>("select * from user where age > @age; select * from address", new { age = 25 }) /// 提示:parms 参数还可以传 Dictionary<string, object> /// /// diff --git a/Providers/FreeSql.Provider.MySqlConnector/FreeSql.Provider.MySqlConnector.csproj b/Providers/FreeSql.Provider.MySqlConnector/FreeSql.Provider.MySqlConnector.csproj index cb32cdbd..3e0ba464 100644 --- a/Providers/FreeSql.Provider.MySqlConnector/FreeSql.Provider.MySqlConnector.csproj +++ b/Providers/FreeSql.Provider.MySqlConnector/FreeSql.Provider.MySqlConnector.csproj @@ -2,7 +2,7 @@ netstandard2.0;net45 - 2.0.100 + 2.0.101 true FreeSql;ncc;YeXiangQin FreeSql 数据库实现,基于 MySql 5.6,Ado.Net 驱动是 MySqlConnector @@ -26,7 +26,7 @@ - +