how to write a jcl prog to copy alternate recs from ps1 to
another ps2,suppose ps1 having 10 recs?
Answers were Sorted based on User's Feedback
To do so we require OUTFIL and SPLIT option of DFSORT.
//STEPNAME EXEC PGM=SORT
//SORTIN DD DSN=SORTIN.INPUT.FILE.TO.SPLIT,DISP=SHR
//PS1 DD DSN=PS1.FILE,DISP=SHR
//PS2 DD DSN=PS2.FILE,DISP=SHR
//SYSIN DD *
OUTFIL FNAMES=(PS1,PS2),SPLIT
/*
This will write 1st, 3rd,5th ....record in the PS1 and
2nd,4th,6th ....record in ps2 file.
| Is This Answer Correct ? | 14 Yes | 3 No |
Answer / mahesh
//step1 exec pgm=iebgener
//sysut1 dd dsn=fss149.mahesh.ps1,disp=(shr)
//sysut2 dd dsn=fss149.mahesh.ps2,disp=shr
| Is This Answer Correct ? | 2 Yes | 23 No |
What does the statements: typrun=scan and typrun=hold do in a JCL statement
On the DD statement, what is the main difference between creating a new sequential flat file and a partitioned dataset?
What is the difference between specifying DISP=OLD and DISP=SHR for a dataset?
What is NOTCAT ?
What is the difference between specifying DISP=OLD and DISP=SHR for a dataset?
what is use of disp parameter in dd statement?
We are aware of eliminating the duplicate records from outyput fiel using sort utility. Can we get the duplicate records in to another file in the Same sort utility?
Explain about ISPF/TSO Commands
i just need the first and last record from a sequencial file?how
what is fixed length and variable length and difference between them
Whats error code s222?
Hi Guyz, My requirement is to empty out a PS file but not to delete. How would I do that. Is there any Utility. If any other way, plz answer. Thanks.
9 Answers iGate, Lehman Brothers,