How to fetch even records from one file to another file by
using ICETOOL in JCL?

Answer Posted / harsha

//STEP1 EXEC PGM=SORT
//SYSPRINT DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=INPUT.DATA,DISP=SHR
//OUTDATA DD DSN=OUTPUT.DATA,DISP=(NEW,CATLG,DELETE)
.
.
.
//SYSIN DD *
OPTION COPY
OUTFIL FNAMES=OUTDATA,SAMPLE=2

THIS WILL COPY ALL EVEN RECORDS
-------------------------------------------
FOR ODD RECORDS
OUTFIL FNAMES=OUTDATA,STARTREC=1,SAMPLE=2

Is This Answer Correct ?    5 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

I HAVE A VB BLOCK WHICH IS USED AS INPUT IN COBOL CONATINING SOME RECORDS CAN I CHANGE THE FILE FROM VB TO FB?

2095


Suppose I have a program in cobol name ”careerride” and want to execute the program by jcl. Specify the process?

668


Explain about LMQUERY�give a dialog information about a data set

896


I need exexution process for JCL programs

1847


How to execute 2nd and 4th steps among 5 steps in jcl proc?

747






what is DSN in JCL and what are the parameters to declare the DSN?

714


How gdg are concatenated?

668


what is the purpose of coding class parameter in job statement?

713


WORKING-STORAGE SECTION. 77 W-A PIC 9(3)V99 VALUE 23.75. 77 W-B PIC ZZ9V99 VALUE 123.45. PROCEDURE DIVISION. MOVE W-A TO W-B. DISPLAY W-B. STOP RUN. compiler : IGYGR1080-S A "VALUE" clause literal was not compatible with the data category o subject data item. The "VALUE" clause was discarded. WORKING-STORAGE SECTION. 77 W-A PIC 9(3)V99 VALUE 23.75. 77 W-B PIC ZZ9V99. PROCEDURE DIVISION. MOVE 123.45 TO W-B. MOVE W-A TO W-B. DISPLAY W-B. STOP RUN. 2375

1033


How to resolve the error "WER488A JOIN CAPACITY EXCEEDED" I am using SYNCSORT with JOINKEYS to compare 2 files. I am Getting error - > WER488A JOIN CAPACITY EXCEEDED There are 2 files to be compared with about 2 million records each. LRECL is 3665. Can somebody give a pointer as to how to resolve this problem? I am using SYNCSORT with JOINKEYS to compare 2 files. I am Getting error - > WER488A JOIN CAPACITY EXCEEDED There are 2 files to be compared with about 2 million records each. LRECL is 3665. Can somebody give a pointer as to how to resolve this problem?

7595


How to submit a jcl from cics?

658


List the different jcl statements that are not permitted in the procedures?

634


What is notcat 2 - gs?

930


I have a job called careerride and some steps in it as step1,step2. But I want to execute step2 before step1 ? How do I do that?

823


Is their any set of rules for dd? Explain.

655