NET/MASTER Network Control Language (NCL) Programmer's Guide

The Dependent Request and Response Queues
Environments and Command Processing
16–38 106160 Tandem Computers Incorporated
The following screen shows the results of executing the procedure:
(09:26) --------------------- OPERATOR CONTROL SERVICES ----------------------
START ZEX1611N
STATUS
NNM0608 SYSTEM STATUS AS AT 09:26:32
NNM0608 GUARDIAN VERSION: D30
NNM0608 SYSTEM STATE: RUNNING
NNM0608 SYSTEM WAS INITIALISED ON MON 15-JUN-1992 AT 09:22:55
NNM1005 START ZEX1611N PROCESSING COMPLETE. NCLID 000007
_____________________________________________________________________________
---------- ------------------ NonStop NET/MASTER D30 ---------------- --------
M=>
Example With the INTCMD, INTREAD, and INTCLEAR Verbs
The following NCL procedure shows a more complex example of the INTCMD,
INTREAD, and INTCLEAR verbs. (The INTCONT verb is not required; the SAY core
statement is used to display results.)
zex1612n: PROCEDURE
/* Get single NonStop NET/MASTER PARAM value using the INT* verbs */
/* Change NCL procedure name from ZEX1612N to PARAM to enter the */
/* "PARAM" command from the OCS command input line. */
CONTROL SHRVARS=&param /* Set variable sharing */
&param = &SYS.ALLPARMS /* Initialize variable */
IF &param = "" THEN /* If no PARAM specified*/
CMD "-SHOW PARAM" /* display all PARAMs */
ELSE /* else */
SAY &param" is "get_value(&param) /* display value */
get_value: FUNCTION /* Function to get value*/
CONTROL NOCMD /* Disable command echo */
INTCLEAR TYPE=ALL /* Clear dep. queues */
INTCMD "SHOW PARAM" /* Execute SHOW PARAM */
DO UNTIL &msgno = "NNM0999" OR, /* DO loop sets exit */
&found > 0 /* conditions */
INTREAD VARS=(&msgno(7),*,&text), /* Read message into */
TYPE=ANY PARSE=NO /* variables */
&found = POS(&param"=",&text) /* Check for PARAM */
IF &found > 0 THEN /* If PARAM found then */
&value = SPACE(REMSTR('=',&text)) /* get value */
ELSE /* else */
&value = "not a valid value" /* not valid */
END /* End DO loop */