?
Solved

Oracle Trigger Problem - ORA-06519

Posted on 2012-03-26
2
Medium Priority
?
915 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 35

Expert Comment

by:johnsone
ID: 37768408
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 2000 total points
ID: 37768580
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

NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function
This video shows how to configure and send email from and Oracle database using both UTL_SMTP and UTL_MAIL, as well as comparing UTL_SMTP to a manual SMTP conversation with a mail server.

770 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