maximum number of recursive SQL levels (50) exceeded [message #303367] |
Fri, 29 February 2008 01:09 |
ram anand
Messages: 244 Registered: February 2008 Location: india
|
Senior Member |
|
|
Hi guys,
I have created a trigger
CREATE OR REPLACE TRIGGER TRG_CUSTOMER_GROUP_I
BEFORE INSERT
ON CUSTOMER_GROUP
FOR EACH ROW
DECLARE
V_COUNT NUMBER(9);
BEGIN
SELECT COUNT(*)
INTO V_COUNT
FROM CUSTOMER
WHERE CUSTOMER_ID =:NEW.CUSTOMER_GROUP_ID;
IF (V_COUNT = 0) THEN
RAISE_APPLICATION_ERROR(-20100,'error occured (CUSTOMER.CUSTOMER_IDDOESNOTEXISTS)');
ELSE
INSERT INTO CUSTOMER_GROUP(CUSTOMER_GROUP_ID,CUSTOMER_GROUP_NAME)
VALUES (:NEW.CUSTOMER_GROUP_ID,:NEW.CUSTOMER_GROUP_NAME);
END IF;
END;
/
INSERT INTO CUSTOMER_GROUP ( CUSTOMER_GROUP_ID, CUSTOMER_GROUP_NAME)
VALUES ( 'sample', 'sample');
/
while I insert a record into it the below error throws.so can any one give me a proper explaination for the below error mentioned,pls
ORA-00036: maximum number of recursive SQL levels (50) exceeded
ORA-06512: at "OPSDEV.TRG_CUSTOMER_GROUP_I", line 4
ORA-04088: error during execution of trigger 'OPSDEV.TRG_CUSTOMER_GROUP_I'
ORA-06512: at "OPSDEV.TRG_CUSTOMER_GROUP_I", line 11
ORA-04088: error during execution of trigger 'OPSDEV.TRG_CUSTOMER_GROUP_I'
ORA-06512: at "OPSDEV.TRG_CUSTOMER_GROUP_I", line 11
ORA-04088: error during execution of trigger 'OPSDEV.TRG_CUSTOMER_GROUP_I'
ORA-06512: at "OPSDEV.TRG_CUSTOMER_GROUP_I", line 11
ORA-04088: error during execution of trigger 'OPSDEV.TRG_CUSTOMER_GROUP_I'
ORA-06512: at "OPSDEV.TRG_CUSTOMER_GROUP_I", line 11
ORA-04088: error during execution of trigger 'OPSDEV.TRG_CUSTOMER_GROUP_I'
ORA-06512: at "OPSDEV.TRG_CUSTOMER_GROUP_I", line 11
ORA-04088: error during execution of trigger 'OPSDEV.TRG_CUSTOMER_GROUP_I'
ORA-06512: at "OPSDEV.TRG_CUSTOMER_GROUP_I", line 11
ORA-04088: error during execution of trigger 'OPSDEV.TRG_CUSTOMER_GROUP_I'
ORA-06512: at "OPSDEV.TRG_CUSTOMER_GROUP_I", line 11
ORA-04088:
Thanks,
[Updated on: Fri, 29 February 2008 01:14] Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|