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: trouble on trigger

Re: trouble on trigger

From: Michel Cadot <micadot_at_netcourrier.com>
Date: Thu, 14 Dec 2000 13:42:13 +0100
Message-ID: <91af90$b7e$1@s1.read.news.oleane.net>

If your update statement runs fine in Sql*Plus, i think you have Oracle 8.1.6 or 8.1.7 because this syntax does not exist before.
However, PL/SQL is always behind SQL and this syntax is not yet supported in trigger or procedure.

--
Have a nice day
Michel


Setiawan Wijaya <swsan_at_flashmail.com> a écrit dans le message : 2Zd_5.11642$K6.85838_at_news...

> I have a trigger, when I'm running the update query it's fine but when i'm
> put into trigger it's error
>
>
> CREATE OR REPLACE TRIGGER EXCHG_RATE
> AFTER UPDATE ON CURRENCY
> FOR EACH ROW
> BEGIN
> UPDATE PRICE
> SET SELL_PRICE =
> CASE WHEN EXTRA_COST_CURRENCY = 'IDR' THEN
> ROUND(((25* COST_PRICE) + EXTRA_COST_PRICE) *
> (1+(MARGIN_PERCENTAGE/100)),-3)
> ELSE
> ROUND(((25* COST_PRICE) + (25* EXTRA_COST_PRICE)) *
> (1+(MARGIN_PERCENTAGE/100)),-3)
> END
> WHERE COST_PRICE_CURRENCY = 'USD';
> END;
> /
>
>
>
> Please help me find the error...
>
> Thanks,
> Setiawan Wijaya
>
>
>
Received on Thu Dec 14 2000 - 06:42:13 CST

Original text of this message

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