Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Triggers and calculated fields
You don't have to use a update clause in your trigger because it is a
statement/row trigger for update. Use before update and by using the old and
new value of your column(s) in your trigger, you can recalculate your
columns before update to table.
HTH John Chiu
Michael <Michael.Wrobel_at_unisys.com> wrote in message
news:82mog4$o5g$1_at_mail.pl.unisys.com...
> I want to use triggers to update calculated fields. I am creating a
trigger
> for each row after an insert, update, or delete. Something with the
trigger
> is not going through because no updates that were specified in the trigger
> are happening. Has anyone used triggers to keep calculated fields
updated.
> Is there a recommended strategy?
>
> I have 6 fields and if any are inserted, updated, or deleted, I want to
run
> an automatic recalculation for 2 calculated fields. I have been
attempting
> the recalculation with an update clause inside of the trigger.
>
> Thanks,
>
> Mike
>
>
Received on Thu Dec 09 1999 - 05:39:21 CST