a input file contains 1000 records, how to move the first
500 record into one out put file and how to move to second
500 records to anothere output file
Answer Posted / varsha
Using SPLITBY option, you can do it in one step only -
//JOBNAME
//STEP1 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=INPUT DSN,DISP=SHR
//OUT1 DD DSN=OUTPUT DSN1,DISP=(NEW,CATLG),
// SPACE=(CYL,(5,5)),UNIT=SYSDA
//OUT2 DD DSN=OUTPUT DSN2,DISP=(NEW,CATLG),
// SPACE=(CYL,(5,5)),UNIT=SYSDA
//SYSIN DD *
SORT FIELDS=COPY
OUTFIL FNAMES=(OUT1,OUT2),SPLITBY=500
/*
//
Please correct .. if I am wrong
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
Suppose there are 2 Input files Infile-1 and Infile-2. Both the Files contain Employee Records. You need to compare both the files and Write the Common Records in third file named Outfile. How can we do this using File-Aid?
which utility is used to sort a file in jcl?
hello friends ,i have exam in Hsbc,pls any on send me placement papers and technical questions on mainframes,thank u
define cond parameter in jcl?
I had Records in file Like this Company Code IBM 2 IBM 1 IBM 4 WIPRO 3 WIPRO 2 WIPRO 9 TCS 4 TCS 6 TCS 3 i want the record of every company with highest code How can i do that?
what is DSN in JCL and what are the parameters to declare the DSN?
What are the 4 fields in dd statement?
Explain about ISPF/TSO Commands
which utility is used to run a cobol-db2 program?
what is a jcl?
Which statement is used to identify the private libraries in job?
How to pass data to a program that is coded in an exec statement?
How does jcl specify the job to the operating system?
Can we use DISP=SHR in output file in JCL
which utility is used a dummy utility?