发布网友 发布时间:2022-04-09 07:09
共7个回答
懂视网 时间:2022-04-09 11:30
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)
获取数据库分组后的最大值
标签:
热心网友 时间:2022-04-09 08:38
SQL> with a as (select 1 a,0 b,'c1' c,'d1' d from al热心网友 时间:2022-04-09 09:56
select * from templet where t_num in (SELECT MAX(t_num) FROM templet GROUP BY T_name)热心网友 时间:2022-04-09 11:31
你这样肯定会出错哟热心网友 时间:2022-04-09 13:22
SELECT top1 FROM templet GROUP BY T_name ORDER BY MAX(t_num) HAVING MAX(t_num);热心网友 时间:2022-04-09 15:30
select name,sum(T_num) as t_num,sum(classcode) as classcode from templet group by name热心网友 时间:2022-04-09 17:55
试试这个怎么样