[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

Re: [sqr-users] Calling Oracle Procedure with MULTIPLE out parameters



This works for me on oracle 8i and sqr 5/6

BEGIN-SQL ON-ERROR=get_error
BEGIN
CMS.WORKLOAD.GET_NEW_ASSIGNMENTS($officer, #v_count_new,#v_SE_report2 , 
#v_IV_report2 );;
END;; 
END-SQL

where the oracle procedure is described as
CREATE OR REPLACE PACKAGE WORKLOAD IS
PROCEDURE GET_NEW_ASSIGNMENTS(v_officer IN VARCHAR2, v_count OUT NUMBER,
         v_SE OUT NUMBER,v_IV OUT NUMBER);
END WORKLOAD;
I find it is essential to initialize all the OUT variables in the SQR statement 
first

Kevin LaRoche
Ottawa Ontario


On Nov 28, ven g <vrkpg@yahoo.com> wrote:
> 
> Hi:
>    
>   I have a Oracle stored procedure with multiple IN and OUT parameters, can 
>you please 
let me know how run this in SQR.  I have seen the example with one OUT 
parameters, but 
not with Many or multiple out parameters.  when I tried to assign it to a 
variable, I am 
getting an error.  Any suggestion would be helpful.  Thanks.
>   ===============================
>   Begin-Procedure Get-AvgDlyBal
> begin-sql
> begin
>   $test_out := PACK_DAILYBALANCE.proc_AVGbal ( &MNSVAcctNbr, 
&MNSVSubAcctNbr,'10/01/2006','11/01/2006','Y','Y','Y','Y' );;  ! did not 
include out 
params
> end;;
> end-sql
>         display 'test_out ' noline
>         display $test_out
> end-procedure
>   =========================
>   error message:
>    
>   (SQR 5528) ORACLE OCIStmtExecute error 6550 in cursor 8:
>    ORA-06550: line 1, column 14:
> PLS-00306: wrong number or types of arguments in call to 
>'PROC_AVGDAILYBALROUNDOPTION'
> ORA-06550: line 1, column 7:
> PL/SQL: Statement ignored
>   Error on line 132:
>    (SQR 3735) Could not execute SQL.
>   SQR: Program Aborting.
> 
> 
>  
> ---------------------------------
> Everyone is raving about the all-new Yahoo! Mail beta.
> 
> _______________________________________________
> sqr-users mailing list
> sqr-users@sqrug.org
> <a href='http://www.sqrug.org/mailman/listinfo/sqr-
users'>http://www.sqrug.org/mailman/listinfo/sqr-users</a>
> 

_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users