FastSort Manual

Using FastSort System Procedures
FastSort Manual429834-003
5-12
SORTMERGEFINISH Procedure
subsort-index output
INT:ref:1
receives the relative number of a subsort process that caused the last error. If the
distributor-collector caused the last error or if you did not specify any subsort
processes, SORTPROG sets subsort-index to –1.
subsort-id output
INT:ref:1
receives the CPU and process identification numbers (PINs) of the subsort process
that caused the last error. If you did not specify a subsort processes or if the
distributor-collector process caused the error, SORTPROG sets subsort-id to –
1.
Example
error^length := SORTERRORSUM (sortblock,
buffer,
error^code,
source,
subsort^index,
subsort^id);
SORTMERGEFINISH Procedure
Use SORTMERGEFINISH to end the SORTPROG process after the process
completes the sort or merge run. A sorting or merging error stops the SORTPROG
process when the error occurs. If SORTPROG stops due to an error, the next call to a
FastSort procedure returns an error.
status returned value
INT
returns a FastSort error code if an error occurred; if not, returns 0. For more
information about error messages, see Appendix B, FastSort Error Messages.
3 Scratch file
4 The free-list file (an additional scratch file that SORTPROG allocates for
internal memory management when sorting large amounts of data)
5 Process communication
{ status := } SORTMERGEFINISH ( ctlblock ! i
{ CALL } ,[ abort ] ! i
,[ spare1 ] ! reserved
,[ spare2 ] ) ! reserved
Value Cause of Error