|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Call Oracle Store procedure with refcursor as output type |
« View previous topic :: View next topic » |
Author |
Message
|
ghoshly |
Posted: Thu May 30, 2013 8:49 am Post subject: Call Oracle Store procedure with refcursor as output type |
|
|
Partisan
Joined: 10 Jan 2008 Posts: 333
|
Hello,
I am using WMB 7.0.0.5 and would like to call a Store procedure in Oracle 11g (as sample below) which has a refcursor out parameter.
Code: |
create or replace
procedure test_SP(role IN varchar, dept IN integer, p_cursor out sys_refcursor)
is
begin
open p_cursor for
select EMP.EMPNO, EMP.ENAME, EMP.SAL, demo_states.state_name
from EMP , DEMO_STATES
where EMP.DEPTNO = dept AND
EMP.job = role AND
demo_states.st = 'CA';
end; |
I understand I should not use PASSTHRU, instead I should use CALL statement. I am refering http://publib.boulder.ibm.com/infocenter/wmbhelp/v7r0m0/topic/com.ibm.etools.mft.doc/ac17040_.htm
but not very sure how to call and get the output from refcursor. Is it the same way of resultset?? It would be very helpful if any sample is there. Thanks for your help. |
|
Back to top |
|
 |
lancelotlinc |
Posted: Thu May 30, 2013 9:09 am Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|