MySQL Forums
Forum List  »  Newbie

Re: DELTE with multiple conditions same column does not execute
Posted by: Phillip Ward
Date: July 13, 2022 06:21AM

What "results" would you expect a Delete to display?
It does what it's told - deletes whatever rows it finds that meet the given [where] criteria. Depending on where you run it from, it might tell you how many rows it got rid of.

The syntax is little odd - unless you're actually dealing with lots (and lots) of values, I'd expect to see a "NOT IN" clause here:

DELETE FROM debiteure
WHERE Debiteur = 'Cash-Kelder' 
AND groepnaam NOT IN ( 'SUBSIDIARY', 'UITVOER - ZAR', 'BULK WINE', 'UITVOER - EURO' ) ;

Regards, Phill W.

Options: ReplyQuote


Subject
Written By
Posted
Re: DELTE with multiple conditions same column does not execute
July 13, 2022 06:21AM


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.