Re: [SQL] UPDATE FROM problem, multiple updates of same row don't seem to work

2004-08-11 Thread Bruno Wolff III
On Wed, Aug 11, 2004 at 20:50:28 -0500, David Stanaway <[EMAIL PROTECTED]> wrote: > > I had thought about that, but this is a simpler case of what I need to > do. The operations for each column in the update are dependent on the > current and new values of each row being merged. > > Currently

Re: [SQL] UPDATE FROM problem, multiple updates of same row don't seem to work

2004-08-11 Thread Bruno Wolff III
On Mon, Aug 09, 2004 at 15:16:29 -0500, David Stanaway <[EMAIL PROTECTED]> wrote: > Here is an example: > > CREATE TABLE tablea( > id int PRIMARY KEY, > flag int > ); > > CREATE TABLE tableb( > aid int REFERENCES tablea(id), > flag int > ); > > INSERT INTO tablea VALUES(1,0); > INSERT INTO

[SQL] UPDATE FROM problem, multiple updates of same row don't seem to work

2004-08-09 Thread David Stanaway
Here is an example: CREATE TABLE tablea( id int PRIMARY KEY, flag int ); CREATE TABLE tableb( aid int REFERENCES tablea(id), flag int ); INSERT INTO tablea VALUES(1,0); INSERT INTO tablea VALUES(2,0); -- Flags for 1st row of tablea - When ORed, should be 7 INSERT INTO tableb VALUES(1,1); IN