compilation unit analysis terminated error when compiling a trigger
I created a trigger to execute when someone inserts a row into a table. when I went to compile the trigger after creating it I get the following error:
PL/SQL: ORA-06552: PL/SQL: Compilation unit analysis terminated
It is pointing to line 6. here is the trigger:
DROP TRIGGER AXIUM.PICTURETRG;
CREATE OR REPLACE TRIGGER AXIUM.PICTURETRG
AFTER INSERT
ON AXIUM.PICTURE REFERENCING NEW AS NEW
FOR EACH ROW
DECLARE
vOsUser VARCHAR2(64);
BEGIN
select SYS_CONTEXT('USERENV','OS_USER') into vOsUser from dual;
INSERT INTO AXIUM.PICTUREAUD VALUES (
:NEW."Patient",
vOsUser,
sysdate);
END;
/
Thank you for the quick responce. I will get rid of the drop. however I am not doing a DML on the same table as the trigger. The trigger is executing after an insert on the PICTURE table and it is inserting into the PICTUREAUD table.
Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.
PAVB,
I tried repolacing the line of code you mentioned with your suggestion and went to compile it again and got the same error. I can provide a session log if someone lets me know how to do that.
Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.
"For short logs use copy/paste - for long ones use Attach feature, "Go Advanced" and click on attach button." I am not sure what utility you are using that has those options.
"For short logs use copy/paste - for long ones use Attach feature, "Go Advanced" and click on attach button." I am not sure what utility you are using that has those options.
are you referring to copy/paste?
on the other hand "Go Advanced" is the nice button on the bottom-right of the screen you use to post
Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.
OK, I guess we are not talking about the same thing. My mistake sorry. When I asked someone to tell me how to supply a session log I ment how to I get a session log. once I get the log I now how to attach it or copy and paste What I am not sure on is other then spooling my session to a file how would I get you a session log?
Bookmarks