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)

 

结果:

 

 


 

posted @ 2013-09-16 18:05  难念的经whh  阅读(450)  评论(0编辑  收藏  举报