mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-08-23 13:06:50 +08:00
Add demo
This commit is contained in:
parent
5f2ec713d7
commit
d4f085acee
@ -31,6 +31,13 @@ namespace OrmTest
|
||||
db.Queryable<Order>().AsWithAttr()
|
||||
.LeftJoin<OrderItem>((x,y)=>x.Id==y.OrderId)
|
||||
.ToList();
|
||||
|
||||
var sql1=db.Queryable<OrderItem>().Where(it=>!it.CreateTime.HasValue).ToSqlString();
|
||||
if (!sql1.Contains("NOT( [CreateTime]<>'' AND [CreateTime] IS NOT NULL )"))
|
||||
{
|
||||
throw new Exception("error");
|
||||
}
|
||||
db.GetConnection("OrderItemDb").Ado.ExecuteCommand(sql1);
|
||||
|
||||
}
|
||||
[SqlSugar.Tenant("OrderDb")]
|
||||
|
Loading…
Reference in New Issue
Block a user