当前位置:网站首页>The SQL implementation has multiple records with the same ID, and the latest one is taken
The SQL implementation has multiple records with the same ID, and the latest one is taken
2022-07-05 07:12:00 【Just as young】
SELECT *
FROM(
SELECT fs.*,
ROW_NUMBER() OVER(PARTITION BY fs.new_formname
ORDER BY fs.new_approvedate DESC) fsp
FROM new_flowapproval_steps AS fs
) AS purchase_order_fps
WHERE fsp = 1;
Above , among new_formname For there may be multiple repeated id Field ,new_approvedate Is the time field
边栏推荐
- Docker installs MySQL and uses Navicat to connect
- [software testing] 02 -- software defect management
- SRE核心体系了解
- Ros2 - install ros2 (III)
- Mid 2022 documentary -- the experience of an ordinary person
- [software testing] 06 -- basic process of software testing
- The differences and connections among cookies, sessions, JWT, and tokens
- Log4qt usage of logbase in QT project
- The problem of configuring opencv in qt5.13.2 is solved in detail
- Ethtool principle introduction and troubleshooting ideas for network card packet loss (with ethtool source code download)
猜你喜欢
程序中的负数存储及类型转换
Ros2 - Service Service (IX)
Sre core system understanding
M2DGR 多源多场景 地面机器人SLAM数据集
SD_ CMD_ SEND_ SHIFT_ REGISTER
[MySQL 8.0 does not support capitalization of table names - corresponding scheme]
PHY驱动调试之 --- MDIO/MDC接口22号和45号条款(一)
Ros2 - install ros2 (III)
SOC_ SD_ DATA_ FSM
[vscode] prohibit the pylance plug-in from automatically adding import
随机推荐
Ros2 - install ros2 (III)
Unity ugui how to match and transform coordinates between different UI panels or uis
Ros2 - configuration development environment (V)
Volcano 资源预留特性
PHY驱动调试之 --- MDIO/MDC接口22号和45号条款(一)
C语言数组专题训练
[node] differences among NPM, yarn and pnpm
ROS2——node节点(七)
使用paping工具进行tcp端口连通性检测
数学分析_笔记_第8章:重积分
In C language, int a= 'R'
全局变量和静态变量的初始化
并发编程 — 死锁排查及处理
iNFTnews | 喝茶送虚拟股票?浅析奈雪的茶“发币”
[vscode] prohibit the pylance plug-in from automatically adding import
D2L installation
Executealways of unity is replacing executeineditmode
Docker installs MySQL and uses Navicat to connect
mysql设置触发器问题
Xavier CPU & GPU 高负载功耗测试