ORA-06508: PL/SQL: could not find program unit being called [message #443935] |
Thu, 18 February 2010 01:15 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
ahmadsaeed
Messages: 24 Registered: November 2009 Location: Lahore, Pakistan
|
Junior Member |
![ahmadsaeed321@gmail.com](/forum/theme/orafaq/images/google.png)
|
|
Dear all,
we are facing a problem, your suggestions and comments will be very helpful here.
Actually what happens is that we are connected to oracle through forms 6i. suddenly we receive the error
" ORA-06508: PL/SQL: could not find program unit being called "
while doing some transaction.
we have searched on net and meta link. they say that the package / procedure called has become invalid or recompilation has occurred and that is not compatible.
Now we have monitored carefully that there are no changes what so ever has been made in the the package/ procedure.
what could be the reason behind this.
we have also checked the global variable issue. we use package level variables but declared in the package body only. (so these are not public)
what you say ?
Need your opinion.
Thanks
Ahmad Saeed
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Re: ORA-06508: PL/SQL: could not find program unit being called [message #444028 is a reply to message #444026] |
Thu, 18 February 2010 06:59 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
ahmadsaeed
Messages: 24 Registered: November 2009 Location: Lahore, Pakistan
|
Junior Member |
![ahmadsaeed321@gmail.com](/forum/theme/orafaq/images/google.png)
|
|
This is the code
This is just a procedure call.
Changes are made in some package BILLING.PKG_S06FRM00061 that is compiled all right but the user who is logged in prior to changes need to re-login to press this button and complete its work.
this should not happen
--- From here
BEGIN
BILLING.PKG_S06FRM00061.PREPARE_INVOICE(P_ORDER_TYPE_ID => :PARAMETER.P_ORDER_TYPE_ID,
P_ORDER_NO => :PARAMETER.P_ORDER_NO,
P_LOCATION_ID => :PARAMETER.P_LOCATION_ID,
P_ORDER_LOCATION_ID => :PARAMETER.P_ORDER_LOCATION_ID,
P_MRNO => :PARAMETER.P_MRNO,
P_INVOICE_TYPE_ID => :TEMP_INVOICE_MASTER.INVOICE_TYPE_ID,
P_TEMP_INVOICE_NO => :TEMP_INVOICE_MASTER.INVOICE_NO,
P_ORIGINAL_INVOICE_NO => :PARAMETER.P_ORIGINAL_INVOICE_NO,
P_TEMP_RECEIVE_NO => :TEMP_CASH_RECEIVE_MASTER.RECEIVE_NO,
P_ORIGINAL_RECEIVE_NO => :PARAMETER.P_ORIGINAL_RECEIVE_NO,
P_PATIENT_TYPE_ID => :PARAMETER.P_PATIENT_TYPE_ID,
P_OBJECT_CODE => :PARAMETER.P_OBJECT_CODE,
P_PROCESS_ID => NULL,
P_USER_MRNO => :GLOBAL.USER_MRNO,
P_TERMINAL => :GLOBAL.TERMINAL,
P_EVENT => 'Original Invoice call',
P_TRACK_INVOICE => 'N',
P_CALL_PURPOSE => 'Invoice Insertion',
P_ALERT_TEXT => V_ALERT_TEXT,
P_STOP => V_STOP);
IF V_STOP = 'Y' THEN
DISPLAY_ALERT('MESSAGE', V_ALERT_TEXT);
CLEAR_FORM(NO_VALIDATE);
EXIT_FORM(NO_VALIDATE);
EXIT_FORM(NO_VALIDATE);
ELSE
COMMIT;
END IF;
END;
-- to here
|
|
|
Re: ORA-06508: PL/SQL: could not find program unit being called [message #447089 is a reply to message #444028] |
Thu, 11 March 2010 21:55 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) |
![](/forum/images/custom_avatars/67467.jpg) |
djmartin
Messages: 10181 Registered: March 2005 Location: Surges Bay TAS Australia
|
Senior Member Account Moderator |
|
|
Sorry that I have been so long in replying. Have you solved your problem?
When you change the procedure in the database it is given a new 'object_id' when the new code is inserted and the old code deleted. As your existing session is trying to access the procedure using the previous 'object_id', it will not be found. Therefore, the session has to be closed and a new one started. This is standard Oracle Database behaviour. You should NOT change code while a user is working. If you wish to do this then use dynamic SQL to make the call for you. Just remember that it has to be parsed every time you make the call.
David
|
|
|