1.分页
entity.model.Skip(10*page-1)
2.获取指定个数的数据
entity.model.Take(10)
3.模糊查询
entity.model.Where(p=>p.name.Contains("ss"))
还可以使用StartWith和EndWith,功能见名知
4.更新数据界面不同步
EF上下文帮助我们提高性能,但有些情况下会导致读脏数据的问题 可以使用DataContext.Set<T>().AsNoTracking()来处理 具体位置自行调整

原文:https://www.cnblogs.com/ives/p/8893577.html