Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Help with Mutating Table - Are there other solutions?
No, that's the way to go unless you move the hold to the parent record since
you are saying that all child records should have the same status as a
group.
Jim
"contrapositive" <contrapositive_at_hotmail.com> wrote in message
news:brffbm$2ovpn$1_at_ID-149469.news.uni-berlin.de...
> Two tables, ORDERS and DETAIL_LINES:
>
> ORDERS.order_id
> ORDERS.cust_id
> ORDERS.order_status, etc...
>
> DETAIL_LINES.order_id
> DETAIL_LINES.line_id
> DETAIL_LINES.line_status, etc...
>
> An order has one or more detail lines.
>
> We want an update trigger (for each row) on DETAIL_LINES that says if this
> line_status is being changed to HOLD, then all the other lines for this
> order should change to HOLD. Obviously, that means we're attempting to
> update the table that's being triggered, and the "mutating table" error is
> raised.
>
> I've seen the three triggers and a package approach to this, and I'm ready
> to implement it, but I can't help but think there's some (simpler)
solution
> that I'm overlooking.
>
> Any ideas?
>
> Thanks.
>
> -jk
>
>
Received on Sat Dec 13 2003 - 11:46:20 CST