Create or Replace
trigger UpdateStatus
Before insert or update
of unitsinstock, ReorderLevel
on Product
For each row
Begin
if :new.unitsinstock <= :new.reorderlevel
then
:new.reorderstatus :='1';
else
:new.reorderstatus :='0';
end if;
end;
which processes successfully. I am attempting to execute this updateupdate product set unitsinstock = 5 where upper(productId) = '3043M';
but i keep getting this error message:
Quote
ORA-04098: trigger 'SYSTEM.UPDATESTATUS' is invalid and failed re-validation
[TR]
[TD][/TD]
[/TR]
[/TABLE]
---------- Post added at 04:20 PM ---------- Previous post was at 03:05 PM ----------
Edit: I think it is the trigger. The database has it listed as INVALID. :confused:


Sign In
Create Account


Back to top









