Solved

Oracle Trigger Problem - ORA-06519

Posted on 2012-03-26
2
874 Views
Last Modified: 2012-03-27
I write this trigger and I compile it without errors

DECLARE
tmpVar NUMBER;
pragma AUTONOMOUS_TRANSACTION;
/******************************************************************************
   NAME:       
   PURPOSE:    

   REVISIONS:
   Ver        Date        Author           Description
   ---------  ----------  ---------------  ------------------------------------
   1.0        17/03/2012             1. Created this trigger.

   NOTES:

   Automatically available Auto Replace Keywords:
      Object Name:     
      Sysdate:         17/03/2012
      Date and Time:   17/03/2012, 11:24:45 Õ, and 17/03/2012 11:24:45 Õ
      Username:         (set in TOAD Options, Proc Templates)
      Table Name:       (set in the "New PL/SQL Object" dialog)
      Trigger Options:  (set in the "New PL/SQL Object" dialog)
******************************************************************************/
BEGIN
   tmpVar := 0;
   
   execute immediate 'insert into tbl_testxx select * from tbl_EmpMONTHSALARY';
	/*IF :NEW.emp_id = 30 THEN*/
		/*update TBL_EmpTest
		set fld_EmpId = :NEW.emp_id
		where fld_EmpId not in (:NEW.emp_id);*/
		
		/*INSERT INTO tbl_EmpTest
		FLD_EMPID
		VALUES
		(:NEW.emp_id);*/
	/*END IF;*/			    
END ;

Open in new window


I get this error
ORA-06519
ORA-06512
ORA-04088

Open in new window

0
Comment
Question by:egovernment
2 Comments
 
LVL 34

Expert Comment

by:johnsone
Comment Utility
You are going to need to post the entire trigger definition.

My guess is that the trigger is causing itself to fire again?  Not sure without the full trigger definition.
0
 
LVL 20

Accepted Solution

by:
flow01 earned 500 total points
Comment Utility
beside answering johnsone's post

try coding an  


exception when others then
    rollback;  -- before leaving an AUTONOMOUS_TRANSACTION
                   --  a COMMIT or ROLLBACK should occur
    raise;  -- there was a failure  so reraise
end;

-- to loose the ORA-06519
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Encryption Decryption in Oracle 12 58
statspack purge automate 7 27
recursion example 16 66
control image tags in a string ? 12 58
This article will show, step by step, how to integrate R code into a R Sweave document
A short article about problems I had with the new location API and permissions in Marshmallow
This video shows how to copy a database user from one database to another user DBMS_METADATA.  It also shows how to copy a user's permissions and discusses password hash differences between Oracle 10g and 11g.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now