我有2张桌子:
lang_temp(最新数据):
sku|postid|fi|en|ru (15000 records )
full_products:
sku|postid|fi|en|ru|xx|zzz|aaaa|bbb (15200 records)
postid是独一无二的,它不能相同。
我需要删除lang_temp table /
中不存在的postid的full_products记录谢谢!
答案 0 :(得分:1)
DELETE FROM
full_products
WHERE
NOT EXISTS (SELECT * FROM lang_temp l WHERE full_products.postid = l.postid)