oracle Group by 分组查询后,分页

------------恢复内容开始------------

1.分页查询 select count(*) times,title from menulog group by title order by count(*) desc oracle Group by 分组查询后,分页

2, 生成一个带rn字段的表tableRN=(SELECT rownum as rn, a.* FROM (select count(*) times,title from menulog group by title order by count(*) desc ) a)

oracle Group by 分组查询后,分页

3  select  * from  tableRN where rn between 0 and 6

select * from(SELECT rownum as rn, a.* FROM (select count(*) times,title from menulog group by title order by count(*) desc ) a) 

where rn between 0 and 6

 oracle Group by 分组查询后,分页

 

------------恢复内容结束------------

oracle Group by 分组查询后,分页

上一篇:sqlserver 删除表分区


下一篇:MySQL中将多行查询结果合并为一行展示SQL语句书写