|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Unable to pass env ref to java from esql as INOUT parameter |
« View previous topic :: View next topic » |
Author |
Message
|
makeithappen |
Posted: Sun Dec 18, 2016 4:59 pm Post subject: Unable to pass env ref to java from esql as INOUT parameter |
|
|
Newbie
Joined: 18 Dec 2016 Posts: 1
|
Hi,
when i am trying to pass env reference as INOUT parameter to java method from esql ,I am getting below java reference error.
BIP3202E: (com.xxx.xx.test.getData, 1.1) : An error occurred when trying to resolve the Java class or method 'com.xxx.xx.test.DataUtil.getData' which is referred to by the routine 'getData'.
if i pass env reference as IN parameter it works fine for me. but as i want to store some data in env in java method,i have to pass as INOUT.
Please help me to understand what i am missing here .
SET stat= getData("test",envRef);
ESQL Function
---------------------
CREATE FUNCTION getData(IN test CHARACTER,INOUT envRef REFERENCE)
RETURNS CHARACTER
LANGUAGE JAVA
EXTERNAL NAME "com.xxx.xx.test.DataUtil.getData";
--Java Method
public static String getData(String test,MbElement envRef){
try {
return "OK";
} catch (Exception mbExp) {
return mbExp.getMessage();
}
}
}
Thanks in advance!!  |
|
Back to top |
|
 |
adubya |
Posted: Mon Dec 19, 2016 12:22 am Post subject: |
|
|
Partisan
Joined: 25 Aug 2011 Posts: 377 Location: GU12, UK
|
|
Back to top |
|
 |
fjb_saper |
Posted: Mon Dec 19, 2016 2:36 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Why do you need to pass the parameter as INOUT ? You are not changing the pointer. You are changing the tree structure beneath the pointer.
Just pass the parameter as IN and see what the change does to the structure...  _________________ MQ & Broker admin |
|
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
|
|
|
|