SELECT * from * where name in (select name from (select name from * group by name having count(name)>1)a) and id not in (select id from(select min(id) as id from * group by name having count(name)>1)b) and community=117 and card_num>80000 ORDER BY `*`.`card_num` ASC