求教SQL语句 试试select b.compid,min(count(*)) as cnt from B group by b.compid 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 试试这个那select compid,min(cnt) from (select compid,count(*) as cnt from b group by b.compid ) 不好意思,应该是把compid 去掉. select compid ,count(empid) from b group by compid SELECT * FROM (SELECT COMPID,COUNT(*) COUN FROM BGROUP BY B.COMPID ORDER BY 2)WHERE ROWNUM < 2 SELECT * FROM (SELECT COMPID,COUNT(empid) COUN FROM BGROUP BY B.COMPID ) c where coun =(select min(count(empid)) from b group by compid) 另外只有在8版以上的ORACLE中动态视图才可以加ORDER BY select compid from(select compid,count(*) sl from b group by compid ) t where sl= (select min(count(*)) from b group by compid ) PLSQL能否用对象类型定义一个变量 使用group by查询 linux下oracle 10的安装pdf手册 客户端几乎每天报ora 12560 协议适配器错误 能通过ORACLE SP调用客户端EXE应用程序吗? 如何获取系统表的数据字典? 我们要实现一个统计功能,这个SQL语句不知道怎么写啊(在线等待) oracle 8i 如何配置 (OMS)oracel management server? 急!!!!!!!!!!!!!存贮过程 sql 多列数据分组统计 关于SQL语句的应用问题? 青帮忙解释一下一段关于显示VARRAY中数据的PL/SQL语句?
select compid,count(*) as cnt from b group by b.compid )
GROUP BY B.COMPID ORDER BY 2)
WHERE ROWNUM < 2
GROUP BY B.COMPID ) c where coun =(select min(count(empid)) from b group by compid)
(select compid,count(*) sl from b group by compid ) t
where sl= (select min(count(*)) from b group by compid )