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
What is the function of the dd mgmtclas keyword in sms datasets?
what is use of dcb parameter in dd statement?
Are there any set of rules for the names of the steps used in a job? What are they?
what are the various stages of job processing?
What is the use of symbol // in jcl?
Can we use DISP=SHR in output file in JCL
How to run cobol program using jcl?
What is the function of the steplib dd statement?
Explain how can the attributes of one sms dataset be copied to another dataset?
Explain how can a jobs execution priority be modified?
What is the use of disp parameter?
I have 60 steps in the JCL and want to Execute Only First from PROC by overriding in JCL ?
What methodology can be adapted to transfer data to a program that is coded using the exec statement?
Does jcl support automatic restart?
I have many files which i am receiving from client everyday. I have one step for every file to check for empty or not. Here client gives 30 files i need to check for every file for empty or not and i need to perform 30 steps. Can I do it in single step. Dynamically i need to change the File name in my step.