delete from tb where id in (select id from tb group by id having count(1) = 1)
delete from tb where id in(select id from tb group by id having count(1)=1)
[Quote=引用楼主 ritta1988 的回复:] PL/SQL 查询结果如图,以visual ID为准的数据成对出现,但是有例如倒数第三行visual ID= 91027552A00787 ,只对应一条数据, 这种只出现一次的数据我想要删掉,应该怎么办到呢?delete from table where id in (select id from table group by id having count(1) = 1)
PL/SQL 查询结果如图,以visual ID为准的数据成对出现,但是有例如倒数第三行visual ID= 91027552A00787 ,只对应一条数据, 这种只出现一次的数据我想要删掉,应该怎么办到呢?delete from table where id in (select id from table group by id having count(1) = 1)