× 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 have the following program (subset of the actual program but this will
compile for demonstration purposes) using the QGYOLSPL api to retrieve a
list of the spool files on our systems. When I run the program it is
crashing with escape error message MCH1210 Receiver value too small to
hold result which is not listed in the documentation for the QGYOLSPL api.
We are at v6r1.

Does anyone have any thoughts as to why I am receiving the error message?
I have tried numerous things including copying from posted on the net
and without success I am now definitely into the WAG stage.

Thanks,
Mike Garrison
Werner Enterprises, Inc.


Program Source

D API_OpnLstSplF pr extpgm( 'QGYOLSPL' )
D Receiver 65535a
D ReceiverLen 10i 0
D ListInfo 80a
D NbrOfRcdRtn 10i 0
D SortInfo 1024a
D FilterInfo 1024a
D QualJobName 26a
D FormatOfList 8a
D ErroCode 256a

*? Structures for Open List of Spooled Files API
D/include QSYSINC/QRPGLESRC,QGYOLSPL
D/include QSYSINC/QRPGLESRC,QGY
D/include QSYSINC/QRPGLESRC,QUSEC

* Variables for optional parameters and pointers
D v_RcvVar s 65535a
D v_RcvVarLen s 10i 0 inz(%size( v_RcvVar ))
D v_NbrRcdsRtn s 10i 0 inz( 50 )

D ds_SortInf ds 1024
D siNbrKeys 10i 0 inz
D siStrPos 10i 0 inz
D siFldLen 10i 0 inz
D siDtaTyp 5i 0 inz( x'00' )
D siSrtOrd 1a inz( x'00' )
D siRsv1 1a inz( x'00' )

D ds_FilterInf ds 1024

D v_QualJob s 26a
D v_ListSplfFmt s 8a inz( 'OSPL0100' )

* Errors data structure
D ds_ErrorCode ds 256
D lsErrPrv 10i 0 inz( 256 )
D lsErrAvl 10i 0 inz
D lsErrID 7a inz
D lsErrDta 132a

D ds_LstSplfInf ds 80
D TotRec 10i 0 inz
D RecTrn 10i 0 inz
D ReqHdle 4a inz
D RecLen 10i 0 inz
D InfCmp 1a inz
D CrtDtTm 13a inz
D StsInd 1a inz
D Rsv1 1a inz
D InfRtnLen 10i 0 inz
D Rec1 10i 0 inz
D Rsv2 40a

/free

API_OpnLstSplF( v_RcvVar : v_RcvVarLen : ds_FilterInf :
v_NbrRcdsRtn
: ds_SortInf : ds_FilterInf : v_QualJob : v_ListSplfFmt
: ds_ErrorCode ) ;

*inlr = *on ;
return ;

/end-free

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

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.