As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.
Join the TIBCO Community TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.
From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
Request access to the private WebFOCUS User Group (login required) to network with fellow members.
Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.
I am trying to call a java class from a stored procedure and am getting the below listed error.
InvocationTargetException: ibi.ntj2c.ntjprerr: CALLPGM execution error CPJAVA: Error in processing EXECUTE command for class MyClass
Looking into the documentation I see that the above error may be due to classpath issues. I have set my class to include the jar files for the ntj2c.jar, ibtrace.jar, and the jar file that holds the MyClass class. This was verified by going into the console and seeing the classpath entries listed in the Java Services Configuration area. At this point it looks like I have things set up correctly.
Here is the code within the stored procedure...
CALLJAVA mypackage.MyClass " ", " ", " " -EXIT
Somewhere there is a disconnect and I am not sure where that is.
Also, in the examples in the documentation, the cjsamp class is implementing the callpgm class. Is this required for all java classes call by a stored procesdure with the DM tool?
Any information anyone can provide will be appreciated.
Thank you in advance.
TomThis message has been edited. Last edited by: Kerry,
If this does not work for you, then you may want to open a case with Information Builders' Customer Support Services for assistance, as this issue can be more involved and will need further research. The phone number is 1-800-736-6130, or access online at InfoResponse.
Cheers,
Kerry
Kerry Zhan Focal Point Moderator Information Builders, Inc.
Posts: 1948 | Location: New York | Registered: November 16, 2004
I had actually started with the documentation you provided a link for before posting to this forum. With my not getting any success from following that information and trying a few other things, I ended up opening up a ticket with IBI last week.
You can call the java class : wf installed on windows : DOS JAVA PACKAGE.MYCLASS "PARAM1","PARAM2" wf installed on unix: UNIX JAVA PACKAGE.MYCLASS "PARAM1","PARAM2"
Regards, MtGuy
WF 7.6.2 , iWay 5.5 , Sun Unix , Windows XP , .NET , Oracle , SQL Server and more
I did give that a try with no success. There is somthing missing that I cannot put my finger on.
As listed in my initial entry, the package name and class name are included in the call statement and with this in mind, the syntax looks correct.
Plus the classpath is all set and I can run the class from DOS using the 'java -jar ...' command.
One note though and not sure if this matters. The jar file is located in a directory completely outside of the DM directory structure. I am thinking that this should not matter but will mention it just the same.