mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-04-24 18:04:52 +08:00
Update Demo
This commit is contained in:
parent
f271832a90
commit
eac97593d2
@ -78,8 +78,8 @@ namespace OrmTest
|
|||||||
var dtList = new List<Dictionary<string, object>>();
|
var dtList = new List<Dictionary<string, object>>();
|
||||||
dtList.Add(dt);
|
dtList.Add(dt);
|
||||||
|
|
||||||
var t66 = db.Updateable(dt).AS("student").WhereColumns("id").ExecuteCommand();
|
var t66 = db.Updateable(dt).AS("[Order]").WhereColumns("id").ExecuteCommand();
|
||||||
var t666 = db.Updateable(dtList).AS("student").WhereColumns("id").ExecuteCommand();
|
var t666 = db.Updateable(dtList).AS("[Order]").WhereColumns("id").ExecuteCommand();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -23,13 +23,13 @@ namespace OrmTest
|
|||||||
});
|
});
|
||||||
|
|
||||||
int total = 0;
|
int total = 0;
|
||||||
var list = db.SqlQueryable<Student>("select * from student").ToPageList(1, 2, ref total);
|
var list = db.SqlQueryable<Student>("select * from [order]").ToPageList(1, 2, ref total);
|
||||||
|
|
||||||
|
|
||||||
//by expression
|
//by expression
|
||||||
var list2 = db.SqlQueryable<Student>("select * from student").Where(it => it.Id == 1).ToPageList(1, 2);
|
var list2 = db.SqlQueryable<Student>("select * from [order]").Where(it => it.Id == 1).ToPageList(1, 2);
|
||||||
//by sql
|
//by sql
|
||||||
var list3 = db.SqlQueryable<Student>("select * from student").Where("id=@id", new { id = 1 }).ToPageList(1, 2);
|
var list3 = db.SqlQueryable<Student>("select * from [order]").Where("id=@id", new { id = 1 }).ToPageList(1, 2);
|
||||||
|
|
||||||
Console.WriteLine("#### SqlQueryable End ####");
|
Console.WriteLine("#### SqlQueryable End ####");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user