SQL Server 笔试题总结

1:编写Sql语句,查询id重复3次以上的条目,表为Pramidname

先看建立的表:

SQL语句: 直接使用一个子查询即可

select * from Pram
where id in(select id from Pram
group by id
having COUNT(id)>3)

 

结果:


 

原文地址:https://www.cnblogs.com/TangPro/p/3324751.html