本帖最后由 arrny2002 于 2010-02-10 16:40:29 编辑

解决方案 »

  1.   

    select *
    from A t
    where (select count(1) from A where name=t.name)>1--或者select a.*
    from A,
    (select name,count(1) as cnt from A group by name) B
    where a.name=b.name and b.cnt>1
      

  2.   

    select *
    from 表A t
    where exists (select 1 from 表A where name=t.name and sports!=a.sports)
      

  3.   

    由于不怎么懂数据库,我用 了这句,好像也可以
    select * from A WHERE name in (select name from A group by name having count(*)>1);
    谢谢两位的帮助