Oracle 11gR2.
-----------------------------------------
Hi
I am trying to see the definition of my trigger but when check my result, I see extra line at end of my trigger ALTER TRIGGER "EMP" ENABLE .... What is the reason I am seeing this?
My Query to see definition of trigger:
select dbms_metadata.get_ddl('TRIGGER','EMP')from dual
Result:
CREATE OR REPLACE TRIGGER "EMP"
BEFORE INSERT OR UPDATE
of salary
on employee
for each row
declare
v_error VARCHAR2(20);
begin
if :new.salary > 10
then
v_error:=:old.first_name||' cannot have that much!';
raise_application_error(-20999,v_error);
end if;
end;
ALTER TRIGGER "EMP" ENABLE
Expected Result:
CREATE OR REPLACE TRIGGER "EMP"
BEFORE INSERT OR UPDATE
of salary
on employee
for each row
declare
v_error VARCHAR2(20);
begin
if :new.salary > 10
then
v_error:=:old.first_name||' cannot have that much!';
raise_application_error(-20999,v_error);
end if;
end;