"Andrius Armonas" <[EMAIL PROTECTED]> wrote:
> I'm running mysql 3.23.39. Could anybody explain me how to do this in
mysql
> (without sub-selects):
>
> delete from IP where id in ( select id from USERS where MK='0032' )

One solution is to build a list of id values from the users table in your
application.  If using PHP an easy way to do is loop through each result,
adding to an array then implode the array on "," and save as a $var.  Then
run the delete with "...WHERE id IN ( $var )".

--
Steve Werby
President, Befriend Internet Services LLC
http://www.befriend.com/


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to