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

Answer Posted / dimpy19

1. Using FileAid

//STEP0100 EXEC PGM=FILEAID

//SYSPRINT DD SYSOUT=*

//DD01 DD DSN=YOUR INPUT DATASET,DISP=SHR

//DD01O DD DSN=YOUR OUTPUT FILE IN REVERSE ORDER,

// DISP=(NEW,CATLG,DELETE),UNIT=SYSDA,

// SPACE=(CYL,(X,Y),RLSE)

//SYSIN DD *

$$DD01 COPYBACK

/*

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What rules are followed by the search verb.

631


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

800


What is the usage of comp fields in cobol?

652


What is the Purpose of Pointer in the string?

640


Explain about different table spaces.

643






How do get the result of your program directly on your pc?

1878


what are decleratives in cobol?

1827


What are 77 levels used for?

656


What is the default value(s) for an initialize and what keyword allows for an override of the default?

691


how do you reference the rrds file formats from cobol programs

792


i was faced one question- i have value -00001234.56 Suppress the zeroes and the output should be -1234.56 But Not - 1234.56 spaces should not be available after suppressing the zeroes. logic in jcl and cobol?

892


What is the difference between Structured COBOL Programming and Object Oriented COBOL programming?

672


) how do u code after getting data?

1578


A table has two indexes defined. Which one will be used by the SEARCH?

752


How you can read the file from bottom?

658