MySQL - Delete and Select on same table
May.29, 2008 in
Database
If you want to delete from a table and select from the same table in a subquery (MySQL makes it hard):
DELETE FROM Table1
WHERE id
IN ( SELECT id FROM
(SELECT A.id FROM Table1 A
LEFT OUTER JOIN Table2 B ON B.id = A.other_column WHERE B.id is null)
AS BOGUSTABLENAME)


August 10th, 2008 at 3:13 pm
Çok teşekkür ederim, this sentences mean in english . i very thanks to you.