Running a COBOL Program Using the CL CALL Command
CALL program-nameCALL library-name/program-nameFor further information about using the CL CALL command, see the CL and APIs section of the Programming category in the IBM i Information Center at this Web site -http://www.ibm.com/systems/i/infocenter/.
When you are running a batch job that calls an ILE COBOL program that uses the
Format 1 ACCEPT statement, the input data is taken from the job stream.
This data must be placed immediately following the CL CALL for the ILE COBOL program. You must ensure
that your program requests (through multiple ACCEPT statements) the
same amount of data as is available. See the ACCEPT Statement
section
of the IBM® Rational® Development Studio
for i: ILE COBOL Reference for more information.
If more data is requested than is available, the CL command following the data is treated as input data. If more data is available than is requested, each extra line of data is treated as a CL command. In each instance, undesirable results can occur.