i have 1000 records in input file and i want to sort it and
the first 200 records to be placed in output file. how to
do that??
Answer Posted / satish
hi to all
the example is useful to our requirement,example is i have
some records and i sort it and first 5 records to be placed
in o/p file
//STEP1 EXEC PGM=SORT
//SORTIN DD *
b
c
d
e
f
g
h
i
j
k
l
/*
//OUT DD dsn=output file*
//SYSOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=(1,1,CH,D)
outfil fnames=out,endrec=5
/*
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
what are JCLLIB and STEPLIB in JCL?
Explain how can a jobs execution priority be modified?
What are s0c1, s0c4, s0c5, s0c7 and socb?
what is SOC4 error?
what is use of space parameter in dd statement?
how do you code a null statement?
Explain how can a stopped job be started again?
what disp parameter we mention for creation of temporary dataset so that we can use it in later steps?
Explain how can values be passed from the job stream to an executable program?
List in order the hierarchical levels of jcl?
what is the compile process of cobol program expalin with code
What is jcl in mainframe, and how many types of jcl statements are there for a job?
What is the function of the steplib dd statement?
What is the function of dd name parameter with a 2 part structure; audit.report?
have in 100 records in a file i want to read first 3 records and skip next 3 records and agan i want to read 3 records and again i want to skip 3 records... run a loop from record one to 10 evaluate i/3 if comes even then skip else write to output file