How do you define a sort file in JCL that runs the COBOL
program?

Answer Posted / rik

YOU HAVE TO SIMPLY WRITE THE FOLLOWING CODE IN YOUR JCL :

//STEP1 EXEC PGM=SUPERSRT
//SORTIN DD DSN=TEST001.INFILE,DISP=SHR
//SORTOUT DD DSN=TEST001.SORTED,DISP=(NEW,CATLG,DELETE),
// DCB=(RECFM=FB,LRECL=80,BLKSIZE=0),
// UNIT=WORK,SPACE=(TRK,5,2),RLSE)
//SYSIN DD *
SORT FIELDS=(16,05,ZD,A)
/*

THE CONTAINT OF THE TEST001.INFILE WILL BE COPPIED TO
TEST001.SORTED FILE AND THIS TEST001.SORTED FILE WILL BE
SORTED IN ASCENDING ORDER OF THE CONTAINT OF FIELD POSITION
16 TO 20..

Is This Answer Correct ?    8 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the various section in data division and briefly explain them.

700


what is amode(24), amode(31), rmode(24) and rmode(any)?

705


Which is not true about evaluate statement

1595


If you are current on the owner of a set, what is the difference between an obtain next and obtain first? Actually in which topic will we use dis???Plz explain it clearly

2661


What are all the divisions of a COBOL program?

666






i want to learn mainframe..any websites and material to learn from basic..? my mail id : rajeswaribe2010@gmail.com

1773


Explain how will you differentiate between an internal and an external sort, the pros and cons, internal sort syntax etc

826


Write some characteristics of cobol as means of business language.

621


i want a program using by if, evaluate , string, unstring, perform, occurs?

4065


System Testing for Mainframe Developers What is System Testing? integration testing ? what's the procedure ..

1590


I have a program with an Array of 5000 occurences which is being passed from 5 sub levels to the front end screen. Thess 5 programs using each 5*2 = 10 different arrays with size as 5000. This is causing the transaction to utilize more storage consupmtion. I am looking to reduce the storage consumption. As part of that initially i thought Dynamic array may solve my problem. After viewing the comments given i see its same as normal array. IS there any other way we can resolve this issue?

1232


State the various causes of s0c1, s0c5 and s0c7.

665


What is the difference between external and global variables in COBOL?

815


What the difference is between continue and next sentence?

665


How do you reference the fixed block file formats from cobol programs

709