I have two files each contains 10 records. I would like to
copy both files into one output file but in alternate
sequence. for e.g. first record from file1 then record 2
from file2.....
Answer Posted / mallikharjuna
it will be processed in 3steps
if the data is AAA
AAA
BBB
CCC
FILE2
DDD
EEE
FFF
LIKE 10 RECS
step1:
srt fields=copy
outrec fields=(1:1,3,4:seqnum,4,ZD,START=1,INCR=2 )
STEP:2
step2:
srt fields=copy
outrec fields=(1:1,3,4:seqnum,4,ZD,START=2,INCR=2 )
STEP=3 SORT FIELDS = COPY
OUTREC FIELDS =(1:1,3)
| Is This Answer Correct ? | 9 Yes | 0 No |
Post New Answer View All Answers
State the uses of syspring, sysin, sort fields, sum fields and dummy.
What is the purpose of dd * statement in jcl?
What do you understand by the term job time – out and how can you overcome that?
what is DSN parameter and DISP parameter is used for?
What are some jcl statements that are not allowed in procedures?
Can anybody tell what is tool used to generate the list of PROCS used in JCL to generate a PROCTREE
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.
what are the types of abends that occur on job failure? And explain the possible causes of these
how would you create a temporary dataset? And where will you use them?
What is the function of //cntl statement?
What is notcat 2 - gs?
in a jcl, a large volume dataset is loaded to a table using bmcload in step1 and an image copy of the loaded table is taken using bmccopy in step2. Step2 abends because the image copy dataset cannot hold the volume of the table. How can this be rectified?
Explain dd statement in jcl?
Is condition checking possible in jcl?
Explain how can the attributes of one sms dataset be copied to another dataset?