mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-08-23 22:11:36 +08:00
Add user test case
This commit is contained in:
parent
362638e4d8
commit
6d378321f4
@ -7,6 +7,7 @@ using System.Dynamic;
|
|||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Linq.Dynamic.Core;
|
using System.Linq.Dynamic.Core;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
|
using static OrmTest.UnitStringToExp;
|
||||||
|
|
||||||
namespace OrmTest
|
namespace OrmTest
|
||||||
{
|
{
|
||||||
@ -135,6 +136,15 @@ namespace OrmTest
|
|||||||
.SetColumns("it", $"it.Price== Price+{1} ")
|
.SetColumns("it", $"it.Price== Price+{1} ")
|
||||||
.Where("it", $"it.Id>1 ")
|
.Where("it", $"it.Id>1 ")
|
||||||
.ExecuteCommand();
|
.ExecuteCommand();
|
||||||
|
StaticConfig.DynamicExpressionParserType = typeof(DynamicExpressionParser);
|
||||||
|
StaticConfig.DynamicExpressionParsingConfig = new ParsingConfig()
|
||||||
|
{
|
||||||
|
CustomTypeProvider = new SqlSugarTypeProvider()
|
||||||
|
};
|
||||||
|
var list12 = db.Queryable<Order>()
|
||||||
|
.Where("t1", $" SqlFunc.LessThan(t1.Name, {"aa"})").ToList();
|
||||||
|
var list13 = db.Queryable<Order>()
|
||||||
|
.Where("t1", $" SqlFunc.GreaterThan(t1.Name, {"aa"})").ToList();
|
||||||
Console.WriteLine("#### Examples End ####");
|
Console.WriteLine("#### Examples End ####");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user