|
I am trying to use the RSLVSP MI instruction to check object existence from a procedure at run time. If the object exists everything is fine. If the object doesn't exist I get a MCH error. If I understand the documentation correctly I can set a value in the extended template under the options section to not return the MCH error and just return a null pointer instead.
When I try this I get MCH5601:
Message . . . . : Template value not valid for instruction.
Cause . . . . . : The location of the value is template with an offset to
field in bytes X'FFDC', an offset in field in bits X'0001', a length of
field of 128, and an instruction operand number of 2. The reason code is
X'0000'. If the reason code is X'0000', a reason code may not be available.
Running the value of x'FFDC' through a hex to decimal conversion I get 65,500 which is slightly larger than my field size of 128.
I have searched the RPG archives for an example of using the extended template but didn't see one. Here is what I have based on my understanding of the documentation.
d dsUsrIdxDesc ds Qualified
d TypeCode 1a Inz(x'0E')
d SubtypeCode 1a Inz(x'0A')
d ServicePgm 30a Inz('UT1025UI')
d ReqAuth 2a Inz(x'0001')
d TemplateVer 1a Inz(x'00')
d SearchMethod 1a Inz(x'00')
d Options 1a Inz(x'02')
d Reserved1 7a Inz(x'00')
d ASPToSearch 2a Inz(x'00')
d ASPOfContext 2a
d PtrToContext * ProcPtr
d Reserved2 64a Inz(x'00')
Any ideas what I'm missing?
Rick Chevalier
________________________________
Privileged and Confidential. This e-mail, and any attachments there to, is intended only for use by the addressee(s) named herein and may contain privileged or confidential information. If you have received this e-mail in error, please notify me immediately by a return e-mail and delete this e-mail. You are hereby notified that any dissemination, distribution or copying of this e-mail and/or any attachments thereto, is strictly prohibited.
As an Amazon Associate we earn from qualifying purchases.
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.