Turns out to be 4.1.7
This suggestion fixed my query, thanks.
I'd tried that approach yesterday, but it was on an older
version of MySQL (on our non-production server; I wasn't paying attention
to the versions of MySQL betw. our test and production servers) - so my
previous attempts with this syn
Did you upgrade to 4.0.17 or 4.1.7? In 4.1, you have to use the alias
between FROM and USING:
DELETE FROM rls USING rsrc_linx_specialty rls,...
This is documented at the bottom of the manual page you referenced.
Michael
[EMAIL PROTECTED] wrote:
I had a working query that suddenly doesn't work
What version of MySQL are you using?
Ver 4.1 supports sub-queries.
So, you may issue:
DELETE FROM table2
WHERE msg_id IN(
SELECT msg_id FROM table1
WHERE ((TO_DAYS(NOW()) - TO_DAYS(date_column)) > 45)
)
Thanks
Emery
- Original Message -
From: "Luis Lebron" <[EM
- Original Message -
From: "Steve Buehler" <[EMAIL PROTECTED]>
To: "mysql" <[EMAIL PROTECTED]>
Sent: Thursday, May 23, 2002 8:45 PM
Subject: Deleting from multiple tables
> I am using MySQL with a PHP front end. Is there a better way to delete
> from multiple tables than the following?
> [snip]
> I am using MySQL with a PHP front end. Is there a better way to delete
> from multiple tables than the following?
> $result=mysql_query("DELETE FROM team WHERE team_id = '$team_id'");
> $result=mysql_query("DELETE FROM conflicts WHERE team_id =
> '$team_id'");
> $resu
At 03:34 PM 5/23/2002 -0400, Keith C. Ivey wrote:
>On 23 May 2002, at 12:48, Steve Buehler wrote:
>
> > I am using MySQL with a PHP front end. Is there a better way to delete
> > from multiple tables than the following?
> > $result=mysql_query("DELETE FROM team WHERE team_id = '$team_id'");
On 23 May 2002, at 12:48, Steve Buehler wrote:
> I am using MySQL with a PHP front end. Is there a better way to delete
> from multiple tables than the following?
> $result=mysql_query("DELETE FROM team WHERE team_id = '$team_id'");
> $result=mysql_query("DELETE FROM conflicts WHERE
[snip]
I am using MySQL with a PHP front end. Is there a better way to delete
from multiple tables than the following?
$result=mysql_query("DELETE FROM team WHERE team_id = '$team_id'");
$result=mysql_query("DELETE FROM conflicts WHERE team_id = '$team_id'");
$result=mysql