oracle怎样查出表中重复列的数据?
oracle怎样查出表中重复列的数据?
日期:2019-09-12 17:14:07 人气:1
1、查出表中重复列的数据:select a,count(*) from table group by a having count(*)>1
2、查重复次数最多的列:select a,num from (select a,count(*) num from table group by a having count(*)>1)order by num desc
此外,还有
1、查询一个表中所有字段都相同的记录
比如现在有一人员表 (表名:peosons)若想将姓名、编号、住址这三个字