UNIT3 Sorting and Merging Files
UNIT3 Sorting and Merging Files
Introduction
Unit aims, objectives, prerequisites.
Simple SORTing
This section introduces a simplified version of SORT verb syntax, and
discusses why we might need to sort a file as part of a solution to a
programming problem..
MERGEing files
In this section the MERGE verb is introduced. The MERGE verb may be
used to merge two or more ordered files.
Introduction
Aims As we noted in the tutorial - Processing Sequential Files - it is possible to
apply processing to an ordered sequential file that is difficult, or
impossible, when the file is unordered.
When this kind of processing is required, and the data file we have to work
with is an unordered Sequential file, then part of the solution to the
problem must be to sort the file. COBOL provides the SORT verb for this
purpose.
Sometimes, when two or more files are ordered on the same key field or
fields, we may want to combine them into one single ordered file. COBOL
provides the MERGE verb for this purpose.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 1/26
11/20/2017 Sorting and Merging files
This tutorial explores the syntax, semantics, and use of the SORT and
MERGE verbs.
1. Understand why you might want to sort a file as part of your solution
to a programming problem.
2. Understand the role of the temporary work file and the USING and
GIVING files.
3. Be able to apply the SORT to sort a file on ascending or descending or
multiple keys..
4. Understand why you might want to use an INPUT PROCEDURE or an
OUTPUT PROCEDURE to filter or alter records.
5. Know the difference between an INPUT PROCEDURE and an OUTPUT
PROCEDURE and know when to use one, and when the other.
6. Be able to use the MERGE verb to merge two or more files.
7. Understand the significance of the merge keys.
Selection Constructs
Iteration Constructs
Simple Sorting
Introduction In COBOL programs, the SORT verb is usually used to sort Sequential
files.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 2/26
11/20/2017 Sorting and Merging files
Why sort the Sometimes, processing that is is difficult or impossible to do if the file is
file? unordered, is easy if the file is ordered. In these situations, an obvious part
of the solution is to sort the file. This is an approach to problem solving
sometimes called, "beneficial wishful thinking". We start by thinking if
only this file were ordered, then it would be easy to write the code to
process it, and then take the next logical step which is - "Well then, let's
sort the file first".
The program will use as input, the file CALLS.DAT. This file
contains a record of all the calls made that month. The cost per
unit is �0.10.
SubscriberNum ValueOfCalls
99999999 �999,999.99
99999999 �999,999.99
99999999 �999,999.99
http://www.csis.ul.ie/cobol/course/SortMerge.htm 3/26
11/20/2017 Sorting and Merging files
-------------------------------
Total value = �999,999,999.99
Solving the There are millions of telephone subscribers and, in the course of a month,
problem they will make tens, if not hundreds, of calls. So the calls file will contain
without tens of millions, or hundreds of millions, of records. Is there any viable
sorting the way for a program to produce the report, without first sorting the calls
file? file?
An array or table based solution does not seem viable. For one thing, the
array would have to contain millions of elements. For another, new
subscribers are constantly joining, so the array would have to be re-
dimensioned every time the program ran.
If we had pointers available to us, we might try a linked list or tree based
solution. But the problem with these solutions is that, with millions of
subscribers in the list or tree, the search to find a particular subscriber
would involve a serious performance hit, as well as being complicated to
implement.
And when the calls file ended we would have to read through the entire
Relative file again to create the report.
the cost per unit. This thinking would lead us to the obvious conclusion -
we must sort the calls file.
Syntax of a The syntax for a simplified version of the SORT is shown below. The SORT
simplified takes the records in the InFileName file, sorts them on the
SORT SortKeyIdentifier key or keys and writes the sorted records to the
OutFileName file.
e.g.
SORT notes
The SDWorkFileName identifies a temporary work file that the SORT
process uses for the sort. It is defined in the FILE SECTION using an SD
(Stream/Sort Description) entry. Even though the work file is a temporary
file, it must still have an associated SELECT and ASSIGN clause in the
ENVIRONMENT DIVISION.
Each SortKeyIdentifier identifies a field in the record of the work file. The
sorted file will be in sequence on this key field(s).
Records in LINE When more than one SortKeyIdentifier is specified, the keys decrease in
SEQUENTIAL significance from left to right (leftmost key is most significant, rightmost
files are followed is least significant).
http://www.csis.ul.ie/cobol/course/SortMerge.htm 5/26
11/20/2017 Sorting and Merging files
by the carriage InFileName and OutFileName, are the names of the input and output files
return and line respectively.
feed characters,
but RECORD If the DUPLICATES clause is used then, when the file has been sorted, the
SEQUENTIAL
final order of records with the duplicate keys is the same as that in the
files are
organized as a
unsorted file. If no DUPLICATES clause is used, the order of records with
simple stream of duplicate keys is undefined.
bytes.
AlphabetName is an alphabet-name defined in the SPECIAL-NAMES
paragraph of the ENVIRONMENT DIVISION. This clause is used to select
the character set the SORT verb uses for collating the records in the file.
The character set may be ASCII (8 or 7 bit ), EBCDIC,or user-defined.
SORT rules
SORT example
ENVIRONMENT DIVISION.
INPUT-OUTPUT SECTION.
FILE-CONTROL.
SELECT CallsFile
ASSIGN TO �CALLS.DAT�
ORGANIZATION IS LINE SEQUENTIAL.
SELECT SortedCallsFile
ASSIGN TO �SORTEDCALLS.DAT�
ORGANIZATION IS LINE SEQUENTIAL.
SELECT WorkFile
ASSIGN TO �WORK.TMP�.
DATA DIVISION.
FILE SECTION.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 6/26
11/20/2017 Sorting and Merging files
FD CallsFile.
01 CallRec.
02 SubscriberNumCF PIC 9(8).
02 UnitsUsedCF PIC 9(5).
FD SortedCallsFile.
01 SortedCallRec.
02 SubscriberNumSF PIC 9(8).
02 UnitsUsedSF PIC 9(5).
SD WorkFile.
01 WorkRec.
02 SubscriberNumWF PIC 9(8).
02 UnitsUsedWF PIC 9(5).
etc.
PROCEDURE DIVISION.
Begin.
SORT WorkFile ON ASCENDING SubscriberNumWF
USING CallsFile
GIVING SortedCallsFile.
etc.
How a simple As illustrated by the diagram below, the sort process takes records from
SORT works the input file (CallsFile) and sorts them using the temporary file
(WorkFile) on the field(s), and in the sequence, specified in the KEY
phrase. When all the records have been sorted, the sort process writes
them to the output file (SortedCallsFile).
http://www.csis.ul.ie/cobol/course/SortMerge.htm 7/26
11/20/2017 Sorting and Merging files
Using If you examine the SORT syntax diagram above, carefully, you will realize
multiple that, not only can a file be sorted on a number of keys, but that one key
keys. can be ascending while another can be descending. This is illustrated in
the table below. The table contains a sales file that has been sorted into
descending VendorNumber, within ascending ProvinceCode, by the
following SORT statement;
Notice that ProvinceCode is the major key, and that VendorNumber is only
in descending sequence, within ProvinceCode. The first key named in a
SORT statement is the major key and keys get less significant with each
successive declaration.
SortedSalesFile
http://www.csis.ul.ie/cobol/course/SortMerge.htm 8/26
11/20/2017 Sorting and Merging files
4 56789 etc.
4 56789 etc.
4 44444 etc.
SORT syntax
with INPUT
PROCEDURE
e.g.
SORT WorkFile ON ASCENDING CountyNumWF, VendorNumWF
INPUT PROCEDURE RejectNorthernRecs
GIVING SortedSalesFile.
The INPUT PROCEDURE must finish before the sort process sorts the
records supplied to it by the procedure. That's why the records are
RELEASEd to the work file. They are stored there until the INPUT
PROCEDURE finishes and then they are sorted.
How a SORT A simple SORT works by taking records from the USING file, sorting them,
with and and then writing them to the GIVING file. When an INPUT PROCEDURE is
INPUT used, there is no USING file, so the SORT process has to get its records
PROCEDURE from the INPUT PROCEDURE . The INPUT PROCEDURE uses the
works. RELEASE verb to supply the records to the SORT, one at a time.
When an INPUT PROCEDURE gets its records from an input file it can
select which records to send to the sort process and can even alter the
structure of the records before they are sent.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 10/26
11/20/2017 Sorting and Merging files
where SDRecordName is the name of the record declared in the work file's
SD entry.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 11/26
11/20/2017 Sorting and Merging files
The Foreign Visitors to the CSIS web site are asked to fill in a "guestbook" form. The
Guests form requests the name of the visitor, his/her country of origin and a
Report - comment. These fields are stored, as a fixed length record, in the
example GuestBook file.
program
The example program below prints a report showing the number of
visitors from each foreign country. The records in the GuestBook file are
not in any particular order, so before the report can be printed, the file
must be sorted by CountryName.
$ SET SOURCEFORMAT"FREE"
IDENTIFICATION DIVISION.
PROGRAM-ID. ForeignGuestsRpt.
AUTHOR. Michael Coughlan.
* This program analyses the CSIS web site GuestBook file
* and prints a report showing the number of visitors
* to the web site from each foreign country.
ENVIRONMENT DIVISION.
INPUT-OUTPUT SECTION.
FILE-CONTROL.
SELECT GuestBookFile
ASSIGN TO "GuestBook.Dat"
ORGANIZATION IS LINE SEQUENTIAL.
SELECT WorkFile
ASSIGN TO "Work.Tmp".
SELECT SortedGuestsFile
ASSIGN TO "SortedGuests.Dat"
ORGANIZATION IS LINE SEQUENTIAL.
SELECT ForeignGuestReport
ASSIGN TO "ForeignGuest.Rpt"
http://www.csis.ul.ie/cobol/course/SortMerge.htm 12/26
11/20/2017 Sorting and Merging files
DATA DIVISION.
FILE SECTION.
FD GuestBookFile.
01 GuestRec.
88 EndOfFile VALUE HIGH-VALUES.
02 GuestNameGF PIC X(20).
02 CountryNameGF PIC X(20).
88 CountryIsIreland VALUE "IRELAND".
02 GuestCommentGF PIC X(40).
SD WorkFile.
01 WorkRec.
02 CountryNameWF PIC X(20).
FD SortedGuestsFile.
01 SortedRec.
88 EndOfSortedFile VALUE HIGH-VALUES.
02 CountryNameSF PIC X(20).
FD ForeignGuestReport.
01 PrintLine PIC X(38).
WORKING-STORAGE SECTION.
01 Heading1 PIC X(37)
VALUE "CSIS Web site - Foreign Guests Report".
01 Heading2.
02 FILLER PIC X(25) VALUE " Country".
02 FILLER PIC X(8) VALUE "Visitors".
01 CountryLine.
02 FILLER PIC X(3) VALUE SPACES.
02 PrnCountryName PIC X(20).
02 PrnVisitorCount PIC BBBZZ,ZZ9.
PROCEDURE DIVISION.
PrintGuestReport.
SORT WorkFile ON ASCENDING CountryNameWF
INPUT PROCEDURE IS SelectForeignGuests
GIVING SortedGuestsFile.
READ SortedGuestsFile
AT END SET EndOfSortedFile TO TRUE
END-READ
PERFORM PrintReportBody UNTIL EndOfSortedFile
WRITE PrintLine FROM ReportFooting
AFTER ADVANCING 3 LINES
CLOSE SortedGuestsFile, ForeignGuestReport
STOP RUN.
SelectForeignGuests.
OPEN INPUT GuestBookFile.
READ GuestBookFile
AT END SET EndOfFile TO TRUE
END-READ
PERFORM UNTIL EndOfFile
IF NOT CountryIsIreland
MOVE CountryNameGF TO CountryNameWF
RELEASE WorkRec
END-IF
READ GuestBookFile
AT END SET EndOfFile TO TRUE
END-READ
END-PERFORM
CLOSE GuestBookFile.
PrintReportBody.
MOVE CountryNameSF TO PrnCountryName
MOVE ZEROS TO VisitorCount
PERFORM UNTIL CountryNameSF NOT EQUAL TO PrnCountryName
OR EndOfSortedFile
ADD 1 TO VisitorCount
READ SortedGuestsFile
AT END SET EndOfSortedFile TO TRUE
END-READ
END-PERFORM
MOVE VisitorCount TO PrnVisitorCount
WRITE PrintLine FROM CountryLine
AFTER ADVANCING 1 LINE.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 14/26
11/20/2017 Sorting and Merging files
Feeding the As we noted earlier, because the INPUT PROCEDURE is responsible for
SORT from supplying records to the sort process, the records could be coming from
the keyboard anywhere. We could obtain them from a table, or, as in this example,
- example directly from the user.
program
As the illustration below shows, this example program gets records from
the user, sorts them on ascending StudentId, and then outputs them to the
StudentFile. Notice that the sort process only sorts the file, when the
INPUT PROCEDURE has finished.
$ SET SOURCEFORMAT"FREE"
IDENTIFICATION DIVISION.
PROGRAM-ID. SortInput.
AUTHOR. Michael Coughlan.
* An example program using the SORT and an INPUT PROCEDURE.
* The program accepts records from the user RELEASEs them
* to the work file where they are sorted and then written
* to the StudentFile.
* This program allows student records to be entered in any
* order but creates a file sorted on ascending StudentId.
ENVIRONMENT DIVISION.
INPUT-OUTPUT SECTION.
FILE-CONTROL.
SELECT StudentFile ASSIGN TO "SORTSTUD.DAT"
ORGANIZATION IS LINE SEQUENTIAL.
DATA DIVISION.
FILE SECTION.
FD StudentFile.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 15/26
11/20/2017 Sorting and Merging files
SD WorkFile.
01 WorkRec.
02 StudentIdWF PIC 9(7).
02 FILLER PIC X(23).
PROCEDURE DIVISION.
Begin.
SORT WorkFile ON ASCENDING KEY StudentIdWF
INPUT PROCEDURE IS GetStudentDetails
GIVING StudentFile.
STOP RUN.
GetStudentDetails.
DISPLAY "Enter student details using template below."
DISPLAY "Enter no data to end.".
DISPLAY "NNNNNNNSSSSSSSSIIYYYYMMDDCCCCG".
ACCEPT WorkRec.
PERFORM UNTIL WorkRec = SPACES
RELEASE WorkRec
ACCEPT WorkRec
END-PERFORM.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 16/26
11/20/2017 Sorting and Merging files
SORT syntax The syntax diagram below is the complete syntax for the SORT verb.
with OUTPUT
PROCEDURE
e.g.
An OUTPUT PROCEDURE only executes after the file has been sorted.
How the An OUTPUT PROCEDURE uses the RETURN verb to retrieve sorted records
OUTPUT from the work file. An OUTPUT PROCEDURE can do what it likes with the
PROCEDURE records it gets from work file. It could put them into an array, display them
works on the screen, or send them to an output file.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 18/26
11/20/2017 Sorting and Merging files
Creating an An OUTPUT PROCEDURE uses the RETURN verb to read sorted records
OUTPUT from the work file declared in the Sort's SD entry. The syntax of the
PROCEDURE RETURN verb is;
$ SET SOURCEFORMAT"FREE"
IDENTIFICATION DIVISION.
PROGRAM-ID. MakeSummaryFile.
AUTHOR. Michael Coughlan.
ENVIRONMENT DIVISION.
INPUT-OUTPUT SECTION.
FILE-CONTROL.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 19/26
11/20/2017 Sorting and Merging files
DATA DIVISION.
FILE SECTION.
FD SalesFile.
01 SalesRec PIC X(10).
SD WorkFile.
01 WorkRec.
88 EndOfWorkFile VALUE HIGH-VALUES.
02 SalespsnNumWF PIC X(5).
02 QtySoldWF PIC 9(4).
FD SalesSummaryFile.
01 SummaryRec.
02 SalespsnNum PIC 9(5).
02 TotalQtySold PIC 9(6).
PROCEDURE DIVISION.
Begin.
SORT WorkFile ON ASCENDING KEY SalespsnNumWF
USING SalesFile
OUTPUT PROCEDURE IS SummariseSales
STOP RUN.
SummariseSales.
OPEN OUTPUT SalesSummaryFile
RETURN WorkFile
AT END SET EndOfWorkFile TO TRUE
END-RETURN
PERFORM UNTIL EndOfWorkFile
MOVE SalespsnNumWF TO SalespsnNum
MOVE ZEROS TO TotalQtySold
PERFORM UNTIL SalespsnNumWF NOT = SalespsnNum
OR EndOfWorkFile
ADD QtySoldWF TO TotalQtySold
RETURN WorkFile
AT END SET EndOfWorkFile TO TRUE
END-RETURN
END-PERFORM
WRITE SummaryRec
END-PERFORM
CLOSE SalesSummaryFile.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 20/26
11/20/2017 Sorting and Merging files
Revised This example program is a revised version of the Foreign Guest Report
Foreign program. In this example, instead of creating a sorted file which is read to
Guests create the report; the report is created directly from the OUTPUT
Report - PROCEDURE. This has the effect of making the program simpler and
example shorter, since we no longer need all the sorted file declarations.
program
$ SET SOURCEFORMAT"FREE"
IDENTIFICATION DIVISION.
PROGRAM-ID. ForeignGuestsRpt2.
AUTHOR. Michael Coughlan.
* This program analyses the CSIS web site GuestBook file
* and uses an OUTPUT PROCEDURE to print a report showing
* the number of visitors to the web site from each
* foreign country.
ENVIRONMENT DIVISION.
INPUT-OUTPUT SECTION.
FILE-CONTROL.
SELECT GuestBookFile
ASSIGN TO "GuestBook.Dat"
ORGANIZATION IS LINE SEQUENTIAL.
SELECT WorkFile
ASSIGN TO "Work.Tmp".
SELECT ForeignGuestReport
ASSIGN TO "ForeignGuest.Rpt"
ORGANIZATION IS LINE SEQUENTIAL.
DATA DIVISION.
FILE SECTION.
FD GuestBookFile.
01 GuestRec.
88 EndOfFile VALUE HIGH-VALUES.
02 GuestNameGF PIC X(20).
02 CountryNameGF PIC X(20).
88 CountryIsIreland VALUE "IRELAND".
02 GuestCommentGF PIC X(40).
SD WorkFile.
01 WorkRec.
88 EndOfWorkFile VALUE HIGH-VALUES.
02 CountryNameWF PIC X(20).
http://www.csis.ul.ie/cobol/course/SortMerge.htm 21/26
11/20/2017 Sorting and Merging files
FD ForeignGuestReport.
01 PrintLine PIC X(38).
WORKING-STORAGE SECTION.
01 Heading1 PIC X(37)
VALUE "CSIS Web site - Foreign Guests Report".
01 Heading2.
02 FILLER PIC X(25) VALUE " Country".
02 FILLER PIC X(8) VALUE "Visitors".
01 CountryLine.
02 FILLER PIC X(3) VALUE SPACES.
02 PrnCountryName PIC X(20).
02 PrnVisitorCount PIC BBBZZ,ZZ9.
PROCEDURE DIVISION.
PrintForeignGuestReport.
SORT WorkFile ON ASCENDING CountryNameWF
INPUT PROCEDURE IS SelectForeignGuests
OUTPUT PROCEDURE IS PrintGuestReport.
STOP RUN.
SelectForeignGuests.
OPEN INPUT GuestBookFile.
READ GuestBookFile
AT END SET EndOfFile TO TRUE
END-READ
PERFORM UNTIL EndOfFile
IF NOT CountryIsIreland
MOVE CountryNameGF TO CountryNameWF
RELEASE WorkRec
END-IF
READ GuestBookFile
AT END SET EndOfFile TO TRUE
END-READ
END-PERFORM
CLOSE GuestBookFile.
PrintGuestReport.
OPEN OUTPUT ForeignGuestReport
WRITE PrintLine FROM Heading1
AFTER ADVANCING PAGE
http://www.csis.ul.ie/cobol/course/SortMerge.htm 22/26
11/20/2017 Sorting and Merging files
PrintReportBody.
MOVE CountryNameWF TO PrnCountryName
MOVE ZEROS TO VisitorCount
PERFORM UNTIL CountryNameWF NOT EQUAL TO PrnCountryName
OR EndOfWorkFile
ADD 1 TO VisitorCount
RETURN WorkFile
AT END SET EndofWorkFile TO TRUE
END-RETURN
END-PERFORM
MOVE VisitorCount TO PrnVisitorCount
WRITE PrintLine FROM CountryLine
AFTER ADVANCING 1 LINE.
MERGEing files
Introduction It is often useful to combine two or more files into a single large file. If the
files are unordered, this is easy to accomplish because we can simply
append the records in one file to the end of the other. But if the files are
unordered, the task is somewhat more complicated, especially if there are
more than two files, because we must preserve the ordering in the
combined file.
MERGE
http://www.csis.ul.ie/cobol/course/SortMerge.htm 23/26
11/20/2017 Sorting and Merging files
syntax
e.g.
MERGE MergeWorkFile
ON ASCENDING KEY TransDateWF, TransCodeWF, StudentIdWF
USING InsertTransFile, DeleteTransFile, UpdateTransFile
GIVING CombinedTransFile.
MERGE notes
The results of the MERGE verb are predictable only when the records in
the input files are ordered as described in the KEY clause associated with
the MERGE statement. For instance, if the MERGE statement has an ON
DESCENDING KEY StudentId clause, then all the USING files must be
ordered on descending StudentId.
InFileName and OutFileName, are the names of the input and output files
respectively. These files are automatically opened by the MERGE. When
the MERGE executes they must not be already open.
The MERGE can use an OUTPUT PROCEDURE and the RETURN verb to
get merged records from the SDWorkFileName.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 24/26
11/20/2017 Sorting and Merging files
The OUTPUT PROCEDURE only executes after the files have been merged
and must contain at least one RETURN statement to get the records from
the SortFile.
MERGE In this example program, instead of writing code to insert records from a
example transaction file into an ordered master file, we have used the MERGE verb
to merge the files.
ENVIRONMENT DIVISION.
INPUT-OUTPUT SECTION.
FILE-CONTROL.
SELECT StudentFile ASSIGN TO "STUDENTS.DAT"
ORGANIZATION IS LINE SEQUENTIAL.
DATA DIVISION.
FILE SECTION.
FD StudentFile.
01 StudentRec PIC X(30).
FD InsertionsFile.
01 InsertionRec PIC X(30).
FD NewStudentFile.
01 NewStudentRec PIC X(30).
SD WorkFile.
01 WorkRec.
02 StudentIdWF PIC 9(7).
02 FILLER PIC X(23).
PROCEDURE DIVISION.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 25/26
11/20/2017 Sorting and Merging files
Begin.
MERGE WorkFile
ON ASCENDING KEY StudentIdWF
USING InsertionsFile, StudentFile
GIVING NewStudentFile.
STOP RUN.
Copyright Notice
These COBOL course materials are the copyright property of Michael Coughlan.
All rights reserved. No part of these course materials may be reproduced in any form or by any means
- graphic, electronic, mechanical, photocopying, printing, recording, taping or stored in an information
storage and retrieval system - without the written permission of the author.
http://www.csis.ul.ie/cobol/course/SortMerge.htm 26/26