I'm trying to repeat something I did before at another job. There is a stored procedure on a remote DB2 system that returns a result set.  On the local system, I'm trying to do the following:

   connect to the remote DB2 system

   call the stored procedure

   associate the result set from the procedure with a result set locator

      ALLOCATE RESULT SET LOCATOR (:RSLOC) WITH PROCEDURE MYSCHMA.MYPROC

   allocate a cursor for the result set

      ALLOCATE C1 CURSOR FOR RESULT SET :RSLOC

   fetch rows from the cursor and do something with them

   reset the connection to the local system


I did this successfully at my last job, but both the local and remote systems were IBM i.  Now, the local is IBM i and the remote is z/OS.  When I attempt to call the stored procedure, it fails with a SQLSTATE value of 42884:

   No routine was found with the specified name and compatible arguments.

However, if I make the same stored procedure call from an ACS SQL script window, the call is successful and a result set is returned.

Does anyone have an idea why this might be failing when called from an IBM i program (SQLCBLLE)?  [At the prior place I used SQLRPGLE]

As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.