c#通过sqlsugar查询信息并日期排序

c#通过sqlsugar查询信息并日期字段排序

复制代码
public static List<Sugar_Get_Info_Class> Get_xml_lot_xx(string lot_number)
        {
            DBContext<Sugar_Get_Info_Class> db_data = DBContext<Sugar_Get_Info_Class>.OpDB();
            Expression<Func<Sugar_Get_Info_Class, bool>> cd = null;
           
            var list = db_data.Db.Queryable<Sugar_Get_Info_Class>().Where(f => f.lot == lot_number).OrderBy(f => f.exec_date, SqlSugar.OrderByType.Asc).ToList();
            return list;
            
        }

参考相关配置方法:

SqlSugar库操作mysql数据库方法-增删改查_sqlsugar 批量更新-CSDN博客

相关推荐
K姐研究社10 小时前
OiiOii 2.0 实测 – 智能画布实现 AI 视频创作自动化
运维·人工智能·自动化
wang_shu_mo_ran11 小时前
网络编程(一):网络编程初识
运维·服务器·网络
hai31524754312 小时前
九章空间几何对照直译法:通用芯片 / 定制专用芯片 编译适配规则
linux·汇编·bash
姚青&12 小时前
持续交付与 DevOps 体系
运维·devops
ton_tom12 小时前
设备驱动程序编程-Linux2.6.10-kdb安装-32位
linux·运维·服务器
Elastic 中国社区官方博客12 小时前
谁来评判评判者?在 Elasticsearch Workflows 中使用 LLM-as-a-Judge
大数据·运维·人工智能·elasticsearch·搜索引擎·ai·全文检索
dddwjzx12 小时前
嵌入式Linux C应用编程入门——进程 ( 二 )
linux·嵌入式
SSO_Crown13 小时前
AI 招聘管理系统深度评测与选型指南
大数据·运维·人工智能
三十岁老牛再出发13 小时前
07.07.每日总结
c语言·windows·python
cft56200_ln14 小时前
gPTP Master 报文目的 MAC 地址
运维·服务器·网络