FastSort Manual

FastSort Manual429834-003
5-1
5
Using FastSort System Procedures
This section describes the FastSort system library procedures. FastSort procedures
communicate between a user-written application process and a SORTPROG process.
The SORTPROG process runs independently of an application process and by default
resides in the $SYSTEM.SYSnn.SORTPROG program file.
For information about calling these procedures for serial sorting, see Section 4, Sorting
Programmatically. For information about calling these procedures for parallel sorting,
see Section 6, Sorting in Parallel. Both sections contain TAL and COBOL85 examples.
The table below describes the FastSort system library procedures in the order in which
you call them in an application.
In addition to the 350 words required by system procedure calls, the FastSort system
procedures require additional data stack space that is not automatically allocated by
the BINSERV process during compilation. Use the table below to determine the
amount of additional space you need to allocate for an application that calls FastSort
procedures:
Procedure Name Description
SORTBUILDPARM Specifies parameters for parallel sorting, record
blocking, and scratch volume structure.
SORTMERGESTART Begins the SORTPROG process and passes
parameters for a sort or merge run from the calling
process to SORTPROG.
SORTMERGESEND Sends input records from the calling process to the
SORTPROG process, one for each call.
SORTMERGERECEIVE Returns output records from the SORTPROG process to
the calling process, one for each call.
SORTERROR Provides the message text for the last FastSort error
code returned by a procedure.
SORTERRORDETAIL Provides the FastSort error code for the most recent
error and, if an input file caused the error, identifies the
input file.
SORTERRORSUM Provides all information that SORTERROR and
SORTERRORDETAIL provide and identifies the cause
of the most recent error if not an input file.
SORTMERGESTATISTIC
S
Reports information about a sort or merge run and ends
the run.
SORTMERGEFINISH Ends the sort or merge run and stops the SORTPROG
process.