Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

adding columns in table by trigger

948551Jul 13 2012 — edited Jul 20 2012
Hi,
I,ve found a better way of this by using triggers. I' m using Oracle XE 11.2g, with an interactive report and standard form.
APEX 4.0.2. Using SQLDeveloper I've tried:

CREATE OR REPLACE TRIGGER TRIGGER1
BEFORE UPDATE OF QUANTITY,TOTAL_QUANTITY ON STOCK_CONTROL
FOR EACH ROW
BEGIN
TOTAL_QUANTITY_:= QUANTITY + TOTAL_QUANTITY;
END TRIGGER1;

with message
Error(5,1): PL/SQL: Statement ignored
Error(5,1): PLS-00201: identifier 'TOTAL_QUANTITY_' must be declared

I've tried variations of this but still no result, can't get the syntax right, can anyone help?
Thanks
Tim
This post has been answered by Solomon Yakobson on Jul 13 2012
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 17 2012
Added on Jul 13 2012
10 comments
611 views