您可以使用此:
select * from dbo.myDatabase where ([Date] = (select max([Date]) from ) or [Date] = (select min([Date]) from )) and MachineId = '7B788EE88E-6527-4CB4-AA4D-01B7F4048559' -- or any other id
编辑:
由于两台计算机完全有可能具有相同的
date值,因此应更新查询
MachineId以在
where子句中也包含过滤器。我更新了查询以显示此内容。



