I have program P1 which calls file F1 which has 100 records
and following structure
001 ..................
002 ..................
003 ..................
098 ....................
099 ...................
100 ....................
Now I want to read these files and write these records in
file F2 in following manner.
001 ...... 051 .....
002 ...... 052 .....
003 ...... 053 .....
.......... .......
.......... .......
.......... .......
048 ........ 098 ......
049 .......... 099 .......
050 .... 100 ......
Answer Posted / ch. ranveer singh
//Aaaaaaaa JOB ,'ADC',NOTIFY=&SYSUID
BY CH . RANVEER SINGH GURJAR
//STEP1 EXEC PGM=SORT
//SORTIN DD DSN=WW.W.AHOC.ADC.P1,DISP=SHR
//SORTOF1 DD DSN=WW.W.AHOC.ADC.P2,DISP=SHR
//SORTOF2 DD DSN=WW.W.AHOC.ADC.P3,DISP=SHR
//SYSPRINT DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SYSIN DD *
OPTION COPY
OUTFIL FILES=(1,2),SPLITBY=50
/*
//
| Is This Answer Correct ? | 4 Yes | 3 No |
Post New Answer View All Answers
What is the usage of comp fields in cobol?
how do you reference the variable block file formats from cobol programs
State the various causes of s0c1, s0c5 and s0c7.
) how do u code after getting data?
write a cobol logic. i have file that has 10 records .1 record go to first output file and second record goes to 2 output and etc
What is an in line perform? When would you use it? Anything else you wish to say about it.
INREC AND OUTREC? HOW TO SPLIT 5K RECORDS TO DIFFERENT FILES IN A FILE IN COBOL? RESTART IN COBOL-DB2? ISOLATION LEVELS?
how we sort two input files based on a common column and giving one o/p file please send me the coding logic?
Which division and paragraphs are mandatory for a COBOL program?
What is the problem of ordered sequential files access?
Are you comfortable in cobol or jcl?
what is amode(24), amode(31), rmode(24) and rmode(any)?
how to access the file from prodution from changeman tool and to submit a file to production
can anybody post me about file-aid and changemen tools pls and give me reference if any mainframe guys are there
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?