MySQL Forums
Forum List  »  Microsoft Access

What's wrong with this Query?
Posted by: Pedro Lami
Date: October 22, 2009 08:16AM

DELETE
FROM test AS a
WHERE a.ID NOT IN
(SELECT MAX(b.ID)
FROM test AS b
GROUP BY b.ClientADSRef, b.ClientName, b.CreditorName, MAX(b.ID))


The inner select statement selects the appropriate records. All I want to do is delete the ones NOT IN this selection...

Options: ReplyQuote


Subject
Views
Written By
Posted
What's wrong with this Query?
2952
October 22, 2009 08:16AM
1893
October 26, 2009 06:53AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.