Re: [BUGS] RULE: ON DELETE doesn't stack deletes

2002-11-26 Thread Tom Lane
Rod Taylor <[EMAIL PROTECTED]> writes: > Could it be because once the DELETE FROM A has run the tuple no longer > exists in the view? Precisely. OLD is only a macro for the view, and the first delete changes what's in the view ... regards, tom lane --

Re: [BUGS] RULE: ON DELETE doesn't stack deletes

2002-11-26 Thread Stephan Szabo
On Wed, 20 Nov 2002, Malcolm Hutty wrote: > According to the manual you can stack multiple queries in a RULE: > > CREATE RULE name AS ON event > TO object [ WHERE condition ] > DO [ INSTEAD ] action > > where action can be: > > NOTHING > | > query > | > ( query ; query ... ) > | > [ que

Re: [BUGS] RULE: ON DELETE doesn't stack deletes

2002-11-26 Thread Rod Taylor
Confirmed this problem on cvs-tip. Replacing the DO INSTEAD ( DELETE) with DO INSTEAD (INSERT...) allows multiple insert statements which function fine using OLD.a_data and OLD.b_data. So it must be something else. Could it be because once the DELETE FROM A has run the tuple no longer exist