How do you sort in a COBOL program? Give sort file
definition, sort statement syntax and meaning.
Answer Posted / kavya
As he told above we need to specify the sort-file in sd
entry.
But syntax is as follows,
SORT SORT-FILE ON ASCENDING/DESCENDING KEY
USING INPUT-FILE
GIVING OUTPUT-FILE.
We have to specifies the key to sort.
INPUT-FILE is the file to sorted.The sorted OUTPUT is sent
to the OUTPUT-FILE.
Is This Answer Correct ? | 34 Yes | 3 No |
Post New Answer View All Answers
For rewrite, why is it mandatory that file needs to be opened?
What is the difference between structured cobol programming and object alternativelyiented cobol programming?
Which is the default, TEST BEFORE or TEST AFTER for a PERFORM statement?
How arrays can be defined in COBOL?
How do you differentiate between cobol and cobol-ii?
How you can characterize tables in cobol?
Whats the difference between search & search ALL?
what happens if parmparameter passes zero bytes to the program
can anybody post me about file-aid and changemen tools pls and give me reference if any mainframe guys are there
What is the Purpose of POINTER Phrase in STRING command in COBOL?
What are the different data types in cobol?
What is the usage of comp fields in cobol?
What is comp-1 and comp-2?
input 1 input2 ouput1 output2 output 3 1 re 300 1 re 200 1 re 300 3 rc 500 1 re 200 2 rr 400 1 re 300 2 rr 400 1 rc 400 3 rc 500 1 rc 400 2 rr 700 2 rr 700 5 tt 900 5 tt 900 2 inputs r in flat file and output 1 is matched records,ouptput2 is unmatched of input1,output3 is unmatched of input2! how vl u get the output files using sequential order and to check with each and every records! let me know the procedure division ?
How to get the last record in vsam file in cluster? And how can you get the kids file records into your cobol program?