mysql分组取max或min select a.* from tbas_2016  a,(select mmsi, max(utc1) utc1 from tbas_2016 group by mmsi) b
si = b.mmsi and a.utc1 = b.utc1 order si
mysql group by order bysi, a.portid,a.utc1,a.utc2,a.utc3 from tbas_2016 a where
utc1 = (select max(utc1) from tbas_2016 where si) order by mmsi

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。