FastSort Manual

Using FastSort System Procedures
FastSort Manual429834-003
5-13
SORTMERGERECEIVE Procedure
ctlblock input
INT:ref:200
is the same global storage array you name in the call to SORTMERGESTART. You
should not rely on the information in ctlblock, because this information can
change without warning.
abort input
INT:value
specifies when the SORTPROG process should stop:
spare1 and spare2 reserved
are reserved for future parameters. If you specify a value for spare1 or spare2,
FastSort returns an error.
Example
error := SORTMERGEFINISH (sortblock);
SORTMERGERECEIVE Procedure
Use SORTMERGERECEIVE to return the output records from the SORTPROG
process directly to the calling process. Use SORTMERGERECEIVE if you omit the
out-file-name parameter from the call to SORTMERGESTART or if
out-file-name equals all blanks.
status returned value
INT
returns a FastSort error code if an error occurred; if not, returns 0.
0 Specifies that the SORTPROG process stop after completion of the current
sort or merge run. This is the default value.
1 Specifies that the SORTPROG process stop immediately. The calling
process receives system message -5 in its $RECEIVE file:
-5 PROCESS NORMAL DELETION (STOP)
{ status := } SORTMERGERECEIVE ( ctlblock ! i
{ CALL } ,[ record-loc ] ! o
,length ! o
,[ spare1 ] !
reserved
,[ spare2 ] !
reserved
,[ record-loc-ext ] ! o