I need to delete some records based on a JOIN relation. The following works
in Microsoft SQL Server, and the syntax appears to be correct for MySQL, but
it reports "syntax..near 'DELETE FROM ConvInvDet FROM ConvInvDet H...".
What's the proper way to format this for MySQL?
DELETE FROM ConfInvDet
FROM ConfInvDet H LEFT JOIN ConfInvoices I ON I.InvoiceNo=H.InvoiceNo
WHERE I.ID IS NULL;
Basically, I'm trying to delete orphan records. I'm using MySQL 5.
Thanks,
Jesse
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]