File Utility Program (FUP) Management Programming Manual

ORSERV Commands and Responses
File Utility Program (FUP) Management Programming Manual523322-001
5-20
Example
°
A procedure call (such as KEYPOSITION) when ORSERV tried to access
the ZZRELOAD file.
ZSPI-TKN-ERRLIST
is the standard SPI token that begins an error list. The error list ends with
ZSPI-TKN-ENDLIST.
Example
Figure 5-3 shows a TAL example of the SUSPEND command:
Note. Table 4-4, Errors Returned by All ORSERV Commands, on page 4-21
shows the ZSPI-TKN-RETCODE values common to all ORSERV commands.
Note. For more information about all ORSERV error numbers and their corresponding
error lists, see Appendix C, ORSERV Error Messages
.
Figure 5-3. Example of the SUSPEND Command (page 1 of 2)
! ---------------------------------------------------------
! SUSPEND^ORSERV is a high-level integer procedure for the
! SUSPEND command. It assumes that the ORSERV process
! has already been created using PROCESS_LAUNCH_ [NOWAIT] and is
! open. This procedure returns 0 IF successful,
! or an error number, if an error occurs.
! ---------------------------------------------------------
INT PROC SUSPEND^ORSERV (target^file^name) VARIABLE;
! ---------------------------------------------------------
INT .target^file^name; ! Required file name parameter
BEGIN
! ---------------------------------------------------------
! Global variables used are:
! STRUCT .buffer (ZORS^DDL^MSG^BUFFER^DEF);
! INT ORSERV^file^number,
! error, spi^error;
! LITERAL parameter^error = 99;
! ---------------------------------------------------------
! Check for the required target^file^name parameter.
! ---------------------------------------------------------
IF NOT $PARAM (target^file^name) THEN
RETURN parameter^error;
! ---------------------------------------------------------
! Format the command buffer for the SUSPEND command.
! ---------------------------------------------------------
ORSERV^ssid ':=' [ ZSPI^VAL^TANDEM,
ZSPI^SSN^ZORS,
ZSPI^VAL^VERSION ];