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 / krishnan a
1.first use JCL to sort the file then split the file into
two or read the file first 50 record by using count after
reached 50 then move to one file then remaining 50 move to
other file then read file1 and write by using write para
(PERFORM FILE1-WRITE1) then READ SECOND file then write
second FILE2 record(PERFORM FILE2-WRITE2)into the same
output file.
Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
Which mode is used to operate the sequential file?
Explain sorting techniques in cobol program? Provide the sort file definition, the sort statement, its syntax and meaning
What is the default value(s) for an initialize? What keyword will allow for an override of the default?
Define cobol?
1.give the details about WHEN OTHER. 2. how many form are available in evaluate.
Give some examples of command terminators?
What is the default value(s) for an initialize and what keyword allows for an override of the default?
How are the next sentence and continue different from each other?
What are the different rules for performing sort operation?
I have to write to a outfile where the number of records in that file should be the header of that file using IMS.. can anyone help me in this issue
What is static and dynamic call in cobol?
What is redefines clause in COBOL?
) how do u code after getting data?
What guidelines should be followed to write a structured cobol prgm?
How can you get the ksds file records into your cobol program?