select * from test1 a where (a.phone,a.name) in (
select phone,name from test1 group by phone,name having count(*)>1
) and id not in (
select max(id) from test1 group by phone,name having count(*)>1
);
select * from test1 a where (a.phone,a.name) in (
select phone,name from test1 group by phone,name having count(*)>1
) and id not in (
select max(id) from test1 group by phone,name having count(*)>1
);