Re: Wierd rule problem

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Achilleus Mantzios <achill(at)matrix(dot)gatewaynet(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: Wierd rule problem
Date: 2005-01-25 16:22:27
Message-ID: 4037.1106670147@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Achilleus Mantzios <achill(at)matrix(dot)gatewaynet(dot)com> writes:
> CREATE RULE handle_delete_on_kid AS ON DELETE TO kid WHERE
> (NOT old.onlythis) DO INSTEAD DELETE FROM parent
> WHERE (parent.id = old.parid);

Bear in mind that the DELETEs issued by the ON DELETE CASCADE trigger
will be rewritten by this same rule.

There has been debate in the past whether this behavior is a feature or
a bug, but it's unlikely to change soon.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Hendrik Müller 2005-01-25 17:02:46 Re: Wierd rule problem
Previous Message Achilleus Mantzios 2005-01-25 15:41:23 Wierd rule problem