PROTECTED]>
>CC: "rory o'connor" <[EMAIL PROTECTED]>, [EMAIL PROTECTED]
>Subject: Re: efficient DELETE query - 2 tables
>Date: Mon, 10 Dec 2001 08:51:56 -0500
>
>mySQL can't do subselects afaik
>
>Etienne
>
>Harlan Feinstein wrote:
> >
>
mySQL can't do subselects afaik
Etienne
Harlan Feinstein wrote:
>
> Rory> I want to write an efficient query that will delete all records
> Rory> from one table when they show up in another table (pending
> Rory> shipments --> shipped shipments). I can't do it with this:
>
> mysql> DE
Rory> I want to write an efficient query that will delete all records
Rory> from one table when they show up in another table (pending
Rory> shipments --> shipped shipments). I can't do it with this:
mysql> DELETE from pending_2 WHERE pending_2.ordno = ordersearch_2.ordno;
Rory> becau
search_2.ordno/);
for ( @{$pending} ) {
$dbh->do("DELETE FROM pending_2 WHERE ordno=?", undef, $_);
}
take care
rory o'connor wrote:
ro: Date: Sun, 9 Dec 2001 23:40:03 -0600
ro: From: rory o'connor <[EMAIL PROTECTED]>
ro: To: [EMAIL PROTECTED]
I want to write an efficient query that will delete all records from one
table when they show up in another table (pending shipments --> shipped
shipments). I can't do it with this:
mysql> DELETE from pending_2 WHERE pending_2.ordno = ordersearch_2.ordno;
because you can only refer to columns