select * from job_for_search where jobkey in (select jobkey from job_for_search group by jobkey having count(jobkey) > 1) //判断所有根据jobkey重复的元素
DELETE FROM job_for_search
WHERE id IN (SELECT *
FROM (SELECT id FROM job_for_search
GROUP BY jobkey HAVING (COUNT(*) > 1)
) AS A
);
(去除数据库中重复的数据)
回复列表: