cfcProgrammer
Programmer
Hello,
I am trying to use more than one exception in my exception handler but the Stored Procedure will not compile.
I am getting "PLS-00103: Encountered the symbol "WHEN" when expecting one of the following: * & = - + ; < / > at in is mod not rem <an exponent (**)> <> or != or ~= >= <= <> and or like between ||
I am sure it is something simple but being new to PL/SQL it's causing me some grief.. if anyone can help it would be greatly appreciated.
I am trying to use more than one exception in my exception handler but the Stored Procedure will not compile.
I am getting "PLS-00103: Encountered the symbol "WHEN" when expecting one of the following: * & = - + ; < / > at in is mod not rem <an exponent (**)> <> or != or ~= >= <= <> and or like between ||
I am sure it is something simple but being new to PL/SQL it's causing me some grief.. if anyone can help it would be greatly appreciated.
Code:
SELECT D.CANCEL_DATE
INTO V_CANCEL_DATE
FROM DRUG_CARD D, CASE C
WHERE D.CASE_ID = C.CASE_ID
AND C.FILE_NO = P_FILE_NO
AND D.CANCEL_DATE = (SELECT MAX(CANCEL_DATE)
FROM DRUG_CARD D1,
CASE C1
WHERE D1.CASE_ID = C1.CASE_ID
AND C1.FILE_NO = P_FILE_NO);
EXCEPTION
WHEN NODATAFOUND THEN
P_PROCEED := 1
WHEN OTHERS THEN
INTRETVAL := -9000; --GENERAL DATABASE ERROR
P_ERROR_CODE := SQLCODE;
P_ERROR_DESC := SQLERRM;