With no change to the Delphi or Oracle code we are now getting an Oracle error on attempting to call a function within a package.
Using SQL Monitor I have identified a difference between the actual call to Oracle between the two versions of ODAC as follows:
5.80.0.42:
9.7.2:58 08:26:01 SQL Execute: begin
:RESULT := P_FM_JOBS.RUN_ENDDAY(:CUSTID, :CUSTGRP, :OPTBAL, :OPTVEH, :OPTEXP, :OPTVRB, :RUNDATE, :INTERVAL);
end;
59 08:26:01 :RESULT(FLOAT,OUT)=<NULL>
:CUSTID(VARCHAR[0],IN)=<NULL>
:CUSTGRP(VARCHAR[0],IN)=<NULL>
:OPTBAL(VARCHAR[1],IN)='Y'
:OPTVEH(VARCHAR[1],IN)='Y'
:OPTEXP(VARCHAR[1],IN)='Y'
:OPTVRB(VARCHAR[1],IN)='Y'
:RUNDATE(DATE,IN)=<NULL>
:INTERVAL(VARCHAR[0],IN)=<NULL>
The issue is clearly to do with the fact there is a Result parameter and how it is handled by ODAC.81 08:24:51 SQL Execute: begin
P_FM_JOBS.RUN_ENDDAY(:RESULT, :CUSTID, :CUSTGRP, :OPTBAL, :OPTVEH, :OPTEXP, :OPTVRB, :RUNDATE, :INTERVAL);
end;
82 08:24:51 :RESULT(FLOAT,OUT)=<NULL>
:CUSTID(VARCHAR[0],IN)=<NULL>
:CUSTGRP(VARCHAR[0],IN)=<NULL>
:OPTBAL(VARCHAR[1],IN)='Y'
:OPTVEH(VARCHAR[1],IN)='Y'
:OPTEXP(VARCHAR[1],IN)='Y'
:OPTVRB(VARCHAR[1],IN)='Y'
:RUNDATE(DATE,IN)=<NULL>
:INTERVAL(VARCHAR[0],IN)=<NULL>
83 08:24:51 Error: ORA-06550: line 2, column 3:
PLS-00306: wrong number or types of arguments in call to 'RUN_ENDDAY'
ORA-06550: line 2, column 3:
PL/SQL: Statement ignored
Is there something different we need to be doing to call a function in a package with TOraStoredProc now?
Is there a change we can make to our code that will work with both versions of ODAC?
Is this related to this issues mentioned here - http://forums.devart.com/viewtopic.php?f=5&t=27169?
Cheers