I have a sequential file in which there are 50 records. Now
I want to copy all the 50 records in the reverse order into
a new file? The last record in the original file should be
the first record in the new file. How can I do it?

Answer Posted / avinash n

The file could be sorted in the descending order.

Synatx:

SORT FIELDS=(1:Y,CH,D)
where Y = record length.

The output would be in the reverse order!

Is This Answer Correct ?    0 Yes 13 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain how can a jobs execution priority be modified?

734


What is the difference between run mode and addressing mode?

631


what is use of disp parameter in dd statement?

655


Explain the function of job statement in jcl?

644


Where & How Do You Code Identifier In Jcl?

691






If a (+1) generation dataset is created in the first step of a job, how can it be referenced in later steps of the same job for input?

779


How do you submit a job for execution?

635


What does it mean by Restart and Checkpoint in JCL ? How are checkpoints being taken and what is their usage ? How to use Checkpoint macro on a JOBSTEP ?

9207


Can we use DISP=SHR in output file in JCL

951


What statement can be used to send data to another mvs jes3 node?

815


Explain the function of the dd dcb keyword?

694


How do you run a COBOL batch program from a JCL? How do you run a COBOL/DB2 program?

667


What parameter of the job statement is used to limit the cpu time consumed by the job?

834


Explain the function of the steplib dd statement?

637


hello friends ,i have exam in Hsbc,pls any on send me placement papers and technical questions on mainframes,thank u

1661