Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Help with update trigger on same column

Re: Help with update trigger on same column

From: Reza <reza_at_digital-dispatch.co.uk>
Date: Tue, 29 Aug 2000 11:10:57 +0100
Message-ID: <967543981.4183.0.nnrp-04.d4f07aaa@news.demon.co.uk>

See what other columns are updated in the same transaction and use that column in your after update trigger.
Of course you might have already thought about this/ reza
<bikesdp_at_my-deja.com> wrote in message news:8oeml8$82g$1_at_nnrp1.deja.com...
> I need to implement an update trigger on a table that contains
> information about a customer's purchase. When the transaction is
> complete, the price of the sale is updated by the app. Once that
> happens, I then need to go back and adjust the updated row to reflect a
> currency conversion. The update by the app will cause the trigger to
> fire and the trigger will in turn perform an update of the price column.
>
> Is this possible? Wouldn't that be like entering into a loop? The
> update causes the trigger to fire and since the trigger performed an
> update on the same column, it would fire again, and so on and so on.
>
> Any advice on writing this? Should it be a Before or After update
> trigger?
>
> My thoughts in psuedo code:
>
> When update occurs on price column in transaction table
>
> Fire trigger which updates price column in transcation table
>
> Relate session ID to catalog currency and adjust price colum by proper
> conversion rate
>
>
>
> Thanks....
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Received on Tue Aug 29 2000 - 05:10:57 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US