List:General Discussion« Previous MessageNext Message »
From:Michael Widenius Date:July 29 1999 3:54pm
Subject:UPDATE with JOIN
View as plain text  
>>>>> "Para-dox" == Para-dox  <paradox@stripped> writes:

Para-dox> (respond to paradox@stripped)
Para-dox> I need to be able to update one table based on a JOIN with another table,
Para-dox> can this be done? REPLACE can't work since it deletes the row which contains
Para-dox> 30+ other columns of data, only one column needs to be updated, based on a
Para-dox> sum() from another table. I *NEED* this or my project goes to hell, and I
Para-dox> switch to another SQL server. I know MS access supports a statement like
Para-dox> this:

Para-dox> UPDATE INVOICES LEFT JOIN ITMSOLD ON INVOICES.INVNUM = ITMSOLD.INVNUM SET
Para-dox> INVOICES.SUBTOTAL = Sum(ITMSOLD.EXTPRC);

Para-dox> Does MySQL support anything similar?

Para-dox> Regards, Dave

Hi!

Could you get hand of the full syntax for updates with many tables
from access.  I will definitely look at this during the near future...

Regards,
Monty
Thread
UPDATE with JOINPara-dox9 Jul
  • Re: UPDATE with JOINSasha Pachev9 Jul
  • Re: UPDATE with JOINPara-dox9 Jul
  • UPDATE with JOINMichael Widenius29 Jul