重工电子论坛

标题: RRYQ [打印本页]

作者: 李维强-15级    时间: 2021-2-8 14:43
标题: RRYQ
select a.Name,a.MN,b.DataTime,b.Y1,b.V1,b.K1,b.amp1,b.amp2,b.DYDL,b.DYDY,b.rownumber from t_d_Device a INNER JOIN
(
select row_number() over (partition by mn order by  DataId DESC) as rownumber,* from t_o_data where datatime BETWEEN '2021-02-07 00:00:00' and '2021-02-07 23:00:00'
)
as b on a.MN=b.MN where b.rownumber<=20




欢迎光临 重工电子论坛 (http://cqutlab.cn/) Powered by Discuz! X3.1