(sql笔记)如何查重
如何在数据量大的时候找到重复的数据?
select id,SchemeId as s from orderaction GROUP BY SchemeId HAVING COUNT(s)>1
***要是上面看不懂,可以添加count()函数计数***
select id,count(SchemeId) as s from orderaction GROUP BY SchemeId HAVING COUNT(s)>1
如何在数据量大的时候找到重复的数据?
select id,SchemeId as s from orderaction GROUP BY SchemeId HAVING COUNT(s)>1
***要是上面看不懂,可以添加count()函数计数***
select id,count(SchemeId) as s from orderaction GROUP BY SchemeId HAVING COUNT(s)>1