Re: Multiple-table UPDATE unexpected result

2007-02-09 Thread ViSolve DB Team
Hi, Try this, mysql> update atable,btable set atable.b=atable.b+(select sum(b) from btable where btable.a=atable.a) where atable.a=btable.a; mysql> select * from atable; +--+--+ | a| b| +--+--+ | 1| 10 | | 2| 15 | | 3| 23 | | 4| 10 | +--+

Re: Multiple-table Update

2004-03-28 Thread Nitin Mehta
which ver of mysql are you using? multiple table update is possible only with ver starting from 4.0.4. HTH.. Nitin - Original Message - From: "Laercio Xisto Braga Cavalcanti" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Friday, March 26, 2004 11:39 PM Su