In one of intervie, my interviwer asked, I have a file
which contains 4 records I would like to split the 4
different outputs for each record how to do?
Answer Posted / bjoern
//REPRO EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//IN DD DISP=OLD,DSN=IN
//OUT1 DD DISP=OLD,DSN=OUT1
//OUT2 DD DISP=OLD,DSN=OUT2
//OUT3 DD DISP=OLD,DSN=OUT3
//OUT4 DD DISP=OLD,DSN=OUT4
//SYSIN DD *
REPRO IFILE(IN) OFILE(OUT1) COUNT(1)
REPRO IFILE(IN) OFILE(OUT2) SKIP(1) COUNT(1)
REPRO IFILE(IN) OFILE(OUT3) SKIP(2) COUNT(1)
REPRO IFILE(IN) OFILE(OUT4) SKIP(3)
| Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
How to pass data to a program that is coded in an exec statement?
Are there any set of rules for the names of the steps used in a job? What are they?
what is “Cond= even” and “Cond=only”?
Explain the jcl exec statement?
what is the JCL statement consists of?
Differentiate between the joblib and the steplib statements?
I want my job (careerride) to be executed in 1 minute and 2 seconds. How do I do that?
how JCL works?
Explain about LMFREE�free data set from its association with data ID
Is it possible to define dd statements as you want?
a dd statement has 2 types of parameters. Name them?
What do we mean by 'Virtual storage' for a dataset and for a JOBSTEP ? What is the significance of the following statement for a programmer 'Virtual storage results in program addresses being independent of the addresses that actually exist in a computer' ?
What is the purpose of the dd keylen parameter?
What is the function of the dd mgmtclas keyword in sms datasets?
What is notcat 2 - gs?