× 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.



I'm call the API from AJS, Advanced Job Scheduler.
Error Code (TIMEERRCD) defined as 12.

CALL PGM(QWCRTVTM) PARM(TIMERECV TIMERECVL TIMEFORNM TIMENUMF TIMEKEYF TIMEERRCD).

API is failing, error code not valid.

Message . . . . : Error code parameter not valid.
Cause . . . . . : The format of the error code parameter is not correct.
Recovery . . . : Correct the error code parameter and try the request
again. If you do not know the correct format for the error code parameter,
see the APIs topic collection in the Programming category in the IBM i
Information Center, http://www.ibm.com/systems/i/infocenter/.

Paul

-----Original Message-----
From: MIDRANGE-L <midrange-l-bounces@xxxxxxxxxxxxxxxxxx> On Behalf Of Charles Wilt
Sent: Friday, August 30, 2019 12:14 PM
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxxxxxxxx>
Subject: Re: Retrieve System Time Information (QWCRTVTM) API - Error code parameter length

It's the standard API error structure...
https://www.ibm.com/support/knowledgecenter/en/ssw_ibm_i_74/apiref/errorcodeformat.htm


Has to have at least Bytes Provided, if set to 0 then the API will throw an exception.

dcl-ds errorCode qualified inz;
bytesProvided int(10) inz(0);
end-ds;

12 bytes and you get the error message ID dcl-ds errorCode qualified inz;
bytesProvided int(10) inz(%size(errorCode));
bytesAvailable int(10);
errorId char(7);
end-ds;

more than 12, and you can get back the message description (don't forget the reserved field at pos 13) dcl-ds errorCode qualified inz;
bytesProvided int(10) inz(%size(errorCode));
bytesAvailable int(10);
errorId char(7);
*n char(1);
errorText char(80);
end-ds;

Charles




On Fri, Aug 30, 2019 at 9:57 AM Steinmetz, Paul via MIDRANGE-L < midrange-l@xxxxxxxxxxxxxxxxxx> wrote:

For the Retrieve System Time Information (QWCRTVTM) API What is the
length for the Error code parameter?


https://www.ibm.com/support/knowledgecenter/en/ssw_ibm_i_74/apis/qwcrt
vtm.htm


Thank You
_____
Paul Steinmetz
IBM i Systems Administrator

Pencor Services, Inc.
462 Delaware Ave
Palmerton Pa 18071

610-826-9117 work
610-826-9188 fax
610-349-0913 cell
610-377-6012 home

psteinmetz@xxxxxxxxxx
http://www.pencor.com/



--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx To
subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at
https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: https://amazon.midrange.com

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at https://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxx for any subscription related questions.

Help support midrange.com by shopping at amazon.com with our affiliate link: https://amazon.midrange.com

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
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.