The COBOL programme is responsible for handling the internal sorting, and it does so by using an input file, a work file, and an output file. When doing any sort of processing in this environment, it is necessary to recompile the COBOL programme. Internal Sort makes use of two distinct syntaxes, namely:  The USING and GIVING kinds do not need any further processing of the file.  INPUT PROCEDURE and OUTPUT PROCEDURE sorts are able to manipulate data either before or after the sorting process.  The external sort does not rely on COBOL; instead, it makes direct use of the SORT tool and relies on JCL in conjunction with the PGM=SORT command to complete the process.