How to read records from flat file in reverse order through
COBOL program?

Answer Posted / dimpy19

When REVERSED is specified, OPEN statement execution positions the QSAM file at its end. Subsequent READ statements make the data records available in reversed order, starting with the last record


Open INPUT filename REVERSED

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can a Search can be done on a table with or without Index?

800


How do you define a variable of comp-1 and comp-2?

701


i need a small 3d program using inline and outline.

1629


if we have " ibm mainframe ",in that how to remove first and last leading space eg:"ibm mainframe" like that the answer we need

851


Give some examples of command terminators?

751






Have you used comp and comp-3 in your project? And how?

2006


INREC AND OUTREC? HOW TO SPLIT 5K RECORDS TO DIFFERENT FILES IN A FILE IN COBOL? RESTART IN COBOL-DB2? ISOLATION LEVELS?

417


how do you reference the esds vsam file formats from cobol programs

627


What the difference is between continue and next sentence?

651


What is the difference between structured cobol programming and object alternativelyiented cobol?

751


Write the code implementing the perform … varying.

639


if we display var1 then what will b displayed in below condition. 77 var1 pic s9(2) value -10. 77 var1 pic s9(2) value -11. " " " -12. " " " -13. -14 ... ... -19.

5673


I have a File that has duplicate records. I need only those records that occur more than thrice.?

8637


What is the utilization of copybook in cobol?

650


How many bytes S(8) comp field occupy and its maximum value?

1626