Rules for Simple sort verb:
The work file is to be defined by a sort elaboration entry (SD entry).The format of SD entry is as shown below.
The rules below should be taken into considerations while specifying this sort verb
(i) The input, output and the work file are open by the sort statement before the starting begins and are closed by the sort statement itself after the sorting is over.
(ii) There can be any number of the SORT statement in a program.
(iii) The sorting can be completed on any number of keys.
(iv) All the keys on which the sorting is completed should appear with their elaboration in the record explanation of file name1.
(v) The Keys in sort statement do not need any qualification.
(vi) When two or more records in the input file have similar keys.
(vii) The SELECT clauses for the work file file- name-1 is SELECT file-name-1 ASSIGN TO hardware-name.