i have 10,000 records in one input file.i want to sort 1 to
5000 records in one outputfile and remaining records sort in
another output file write the syntax for this?

Answer Posted / muttaiah

@Albert:
IF we are using Outfil, we won't use Skiprec & stopaft.

My Answer:
Step1:
sort fields=copy
outfil files=01,endrec=5000
outfil files=02,startrec=5001,endrec=10000
Step2:
Sort fields=(pos,leng,cha,a or d)

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is it possible to left uncode disp? If yes, how?

708


In sms datasets, what is the function of the dd avgrec keyword?

655


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

750


Explain how can a stopped job be started again?

636


What is Cataloged Procedures?

715






State the uses of syspring, sysin, sort fields, sum fields and dummy.

654


Explain how can the disposition of sysout datasets be set for an entire jobstream?

636


What is the function of a dd statement?

709


What is the function of the dd avgrec keyword in sms datasets?

841


Must tape dataset definitions include vol=ser specifications?

983


what happens in execution stage in job processing?

657


What is use of restart and how to use it?

771


Step 1 RC 4 Step 2 Step 3 I want to know the COND parameter which can be coded in step 2 or 3. Step 2 should be executed based on Step 1 RC and Step 3 should not be executed based on step 1's RC

800


WORKING-STORAGE SECTION. 01 GROSS-PAY. 05 BASIC-PAY PIC 9(5). 05 ALLOWENCES PIC 9(3). PROCEDURE DIVISION. MOVE 1000 TO BASIC-PAY. MOVE 250 TO ALLOWENCES. DISPLAY GROSS-PAY. STOP RUN. 77 W-A PIC 9(3)V99 VALUE 23.75 77 W-B PIC ZZ9V99 VLAUE 123.45 after the statement MOVE W-A TO W-B what will be W-B's value? a.123.75 b.b23.75 (where b indicates space) c.023.75 d.invalid move

854


Is their any limit for data sets?

704