10 2020 档案

摘要:单主键 with T as( SELECT ROW_NUMBER() over (PARTITION By 工件号 order by 检测时间 desc) as rowid,* FROM 检测表 ) delete from T where id not in( select id from T wh 阅读全文
posted @ 2020-10-26 15:26 扶我起来我还要敲 阅读(191) 评论(0) 推荐(0)
摘要:select msd.*,sc.* FROM MachinesShiftDetails as msd OUTER APPLY (select top 1 * from ShiftCalendars where MachineShiftDetailId = msd.Id) as sc 阅读全文
posted @ 2020-10-15 16:50 扶我起来我还要敲 阅读(221) 评论(0) 推荐(0)
摘要:with TS as( SELECT ROW_NUMBER() over (PARTITION By code order by code) as rowid,* FROM StateInfos ) select [Hexcode] ,[DisplayName] ,[Code] ,[Original 阅读全文
posted @ 2020-10-15 16:10 扶我起来我还要敲 阅读(295) 评论(0) 推荐(0)
摘要:查询存在某个属性的记录 db.getCollection('Machine').find({LineCapacityCount:{ $exists: true }}) 删除Machine文档中 Parameter对象的STD::STATUS属性, {} 表示所有 {"multi":true} 表示多 阅读全文
posted @ 2020-10-12 13:40 扶我起来我还要敲 阅读(138) 评论(0) 推荐(0)