输入banner图图片脚本导航/分类

获取数据库分组后的最大值

from scott.emp e, (select e.deptno, max(e.sal) sal from scott.emp e group by e.deptno) me  where e.deptno = me.deptno  and e.sal = me.sal; 

2.查找某个表 lampa 按字段evno分组,求字段inte的最大值

select * from lampa a where 1>(select count(*) from lampa where a.evno=evno and a.inte<inte)

 

获取数据库分组后的最大值

标签: