| |
GeekInterview.com > Interview Questions > Mainframe > COBOL
| Print | |
Question: Explain the difference between an internal and an external sort, the pros and cons, internal sort syntax etc?
Answer: An external sort is not COBOL; it is performed through JCL and PGM=SORT. It is understandable without any code reference. An internal sort can use two different syntaxes: 1.) USING, GIVING sorts are comparable to external sorts with no extra file processing; 2) INPUT PROCEDURE, OUTPUT PROCEDURE sorts allow for data manipulation before and/or after the sort. |
| July 07, 2008 00:31:59 |
#7 |
| Rinkoj |
Member Since: July 2008 Total Comments: 1 |
RE: Explain the difference between an internal and an external sort, the pros and cons, internal sort syntax etc? |
COBOL sort is external sort as it requires workfile to store intermediate sort data. Syntax:
SORT WORKFILE KEY IS EMP_NO USING INFILE GIVING OUTFILE.
INFILE -- Input file WORKFILE -- Intermediate file where sort data will be stored OUTFILE -- completely sorted file.
|
| |
Back To Question | |