You are on page 1of 1

CREATE OR REPLACE TRIGGER TRIG_STATUS

BEFORE INSERT ON PRODUTOS


FOR EACH ROW
DECLARE
VarStatus produtos.status%type;
BEGIN
if (VarStatus < 1)
then
Raise_Application_Error(-20000, 'Status Invalido');
else
xxxxxxxxxxxxxx
xxxxxxxxxx
end if;
END;
/

You might also like