Change the initial value of d$len1 to 6.


DxpQcmdExc Pr ExtPgm('QCMDEXC')
D Command 2000 Const Options(*VarSize)
D CommandLen 15 5 Const
D Cmds S 2000


Cmds = 'WrkQry';


Pat Landrum
Senior Programmer/Analyst
Hanover County School Board
200 Berkley Street - Ashland, VA. 23005
Phone: 804-365-4658 Email: plandrum@xxxxxxx

Notice: This message or any accompanying documents may contain
confidential or privileged information of Hanover County Public Schools.
If you are not the intended recipient, disclosure, copying or
distribution is strictly prohibited by state and federal law. If you
received this message in error, please notify the sender as soon as

-----Original Message-----
From: Srinivas Boggula [mailto:Srinivas.Boggula@xxxxxxxxx]
Sent: Tuesday, March 04, 2008 2:10 PM
To: Midrange Systems Technical Discussion
Subject: Error while calling QCMDEXC API

Hi All,

I am trying to CALL QCMDEXC API from RPGIV program the reason why I am
Running is to run WRKQRY command from RPGIV and I want to store the
results With Query Name. But when trying to execute below command I'm
getting error Message.


d$cmd1 s 256 inz
d$len1 s 15 5 inz(256)

eval $cmd1 = 'WRKQRY'
call 'QCMDEXC'
parm $cmd1
parm $len1

Thanks in advance.


iGATE is Ranked No. 3 in DQ-IDC best IT employer survey and Ranked No.6
by Business Today-Mercer Human Resource Consulting-TNS in a cross
industry survey of Best Companies to work for in India
Information transmitted by this EMAIL is proprietary to iGATE Group of
Companies and is intended for use only by the individual or entity to
whom it is addressed and may contain information that is privileged,
confidential, or exempt from disclosure under applicable law. If you are
not the intended recipient of this EMAIL immediately notify the sender
at iGATE or mailadmin@xxxxxxxxx and delete this EMAIL including any

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2020 by 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].