急问:如何查找出表的分组中id最大的记录? select * from a where id = max(id) group by id 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 这个语句,运行错误:select *from historydatawhere id = max(id)group by CollectorNo,Port SELECT * from Table where id=(SELECT MAX(id) FROM Table) select *from historydatawhere id = (SELECT MAX(id) FROM historydata group by CollectorNo,Port) select *from historydatawhere id = (SELECT MAX(id) FROM historydata group by CollectorNo,Port)正确 关于mysql服务 过几分钟就自动关闭的问题(比较奇怪) sql查询语句 请教 一个MYSQL的语句 fedora 14 自带的mysql的头文件在哪? 关于MySQL 1054错误的问题 急! 怎么把视图存为一张单表? 重新安装mysql,原来的那些权限帐户能倒出来用吗? 请问怎样得到mysql中的BLOB类型的字段值的大小 NT 上已安装好mysql服务器,WIN98 client连接不上,求救 求教一个数据库设计的问题 postgresql 可能不可能预先对表进行分页,然后用一句sql来取出每一页? group by 的问题
select *
from historydata
where id = max(id)
group by CollectorNo,Port
from historydata
where id = (SELECT MAX(id) FROM historydata group by CollectorNo,Port)
from historydata
where id = (SELECT MAX(id) FROM historydata group by CollectorNo,Port)
正确