× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



The command is actually running in one of your QZRCSRVS jobs under QUSRWRK
subsystem. Check the joblogs of all the active QZRCSRVS jobs to see if
you can find your issue.

--
Marshall Dunbar



-----Original Message-----
From: JAVA400-L <java400-l-bounces@xxxxxxxxxxxx> on behalf of Kelly Beard
<kenverybigliar@xxxxxxxxx>
Reply-To: Java Programming on and around the IBM i <java400-l@xxxxxxxxxxxx>
Date: Monday, April 4, 2016 at 4:56 PM
To: java400-l <java400-l@xxxxxxxxxxxx>
Subject: CommandCall() failing but no error messages

I have a bit of Java code that works on one system but not another and I
cannot find anything - spool file, message queue message, job log to tell
me what is wrong with my command call. Even the AS400-Message class is a
fail. I just get 'false' from the run() method. There has to be a job
out
there somewhere that has left a spool file around.

???

boolean runCommand(String commandFinal)
{
boolean commandOK = false;

/*
IBM Java ToolBox CommandCall class.

http://www-01.ibm.com/support/knowledgecenter/ssw_ibm_i_71/rzahh/cmdc.htm
*/
CommandCall command = new CommandCall(m_as400sys);
try {
if ((commandOK = command.run(commandFinal)) != true) {

// Note that there was an error.
m_log.error("Command failed! " + commandFinal);
}

// Show the messages (returned whether or not there was an
error.)
// Note: for the STARTQQENG command this block of code will
never print anything
// unless the STARTQQENG *CMD and CL *PGM code is changed to
do
so.
AS400Message[] messagelist = command.getMessageList();
for (int i = 0; i < messagelist.length; ++i) {

// Show each message.
m_log.info(messagelist[i].getText());
}
}
catch (Exception e) {
m_log.error("Command " + command.getCommand() + " issued an
exception!");
e.printStackTrace();
}
return commandOK;
}

--
Kelly Beard
--
This is the Java Programming on and around the IBM i (JAVA400-L) mailing
list
To post a message email: JAVA400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/java400-l
or email: JAVA400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/java400-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

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.