There are a set of 10 files and a customer will be
selecting random no of files(i.e they may be more than 2,
may not be in the order).Sometimes he might just select
one file or sometimes no files at all.How do you code a JCL
for this? Is it possible to code just JCL alone for this
problem?
Answer Posted / yogendra shinde
Hi,
I don't know the exact answer to this query.
But I have following approach.
Suppose I have a cobol pgm (say) PGM123 that is picking up
files randomly. (We definately need 1 application pgm to
process any of those 10 files randomly. This is my basic
assumption)
I will code a PARM or SYSIN DD * where in my customer can
change order of selection of files .
Say if customer enters PARM as ABCD in order then I will
move this PARM ABCD in a working storage variable in COBOL
PGM and will read each byte A (assign to process file-1)
if second byte is B then process file-2 of third byte is C
then process file-3 and so on. If the cutomer changes this
parm as EDA then files processed will be file-5 then file-4
then file-1.
If any body has different approach pls let me know.
| Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
how to run batch program without jcl?
I have a COBOL program that ACCEPTs some input data. How do you code the JCL statement for this?
Explain how can the disposition of sysout datasets be set for an entire jobstream?
which utility is used to sort a file in jcl?
what is the purpose of coding notify parameter in job statement?
In job processing, what happens in conversion stage?
List the various advantages of using jcl language?
Is acct parameter mandatory?
what is use of space parameter in dd statement?
Which statement is used to identify the private libraries in job?
Name the parameters which can be used to limit the number of records written to a sysout dataset?
What are hierarchy levels in jcl?
What statement can be used to send data to another mvs jes3 node?
How can a jobs execution priority be modified?
What is catelog procedure and how many catelog procedure to use in one job?