日期:2014-05-18 浏览次数:20652 次
select * from test where 洪水量 in (select max(洪水量) from test)
------解决方案--------------------
--查询每天的洪水最大量 select convert(varchar(10), tiTime,20) as 'DailyDate',MAX(洪水量) from tb group by convert(varchar(10), tiTime,20)
------解决方案--------------------
select top (1) * from test order by 供水量 desc
------解决方案--------------------
如果最大供水量有相同的多个,请执行如下代码:
select top (1) with ties * from test order by 供水量 desc