Domain: PROCEDURE
Command description
SHOW-STREAM-ASSIGNMENT shows the current assignment of the specified S variable streams.
Format
SHOW-STREAM-ASSIGNMENT |
STREAM-NAME = *ALL / *STD-STREAMS / <structured-name 1..20 with-wild(40)> / list-poss(100): <structured-name 1..20> ,INFORMATION = *CURRENT-ASSIGNMENT / *FINAL-DESTINATION ,OUTPUT = *SYSOUT / *SYSLST |
Operands
STREAM-NAME =
Name of the S variable stream to be displayed.
STREAM-NAME = * ALL
All the S variable streams which are visible in the current procedure will be listed. In other words, all the S variable streams which were created in the current procedure or in any dependent procedure are listed.
STREAM-NAME = *STD-STREAMS
All the standard variable streams which are implemented in the system will be displayed. The names of these variable streams all have the prefix “SYS”. That is, the output comprises all the SYS streams which are listed in the description of the STREAM-NAME operand of the ASSIGN-STREAM command.
STREAM-NAME = <structured-name 1..20 with-wild(40)>
All the S variable streams which match this search pattern will be displayed.
STREAM-NAME = list-poss(100): <structured-name 1..20> List of the names of S variable streams which are to be displayed.
INFORMATION =
Specifies what information has to be output.
INFORMATION = *CURRENT-ASSIGNMENT
Outputs the name which is set in the TO operand of the ASSIGN-STREAM command.
If the variable stream has been assigned to another variable stream name, then this name is output.
INFORMATION = *FINAL-DESTINATION
Outputs the name of the current server which is linked to the S variable stream.
If the variable stream has been assigned to another variable stream name, then the last assignment is output. If the variable stream is assigned to *STD, *DUMMY, *VAR or *SERVER, this value will be output.
OUTPUT =
Specifies where the output from the command is to be sent.
OUTPUT = *SYSOUT
Output is sent to SYSOUT. The ASSIGN-SYSOUT or ASSIGN-STREAM command can be used to stipulate output to an S variable or an S variable stream, respectively.
OUTPUT = *SYSLST
Output is written to SYSLST only. Structured output is not supported.
Command return codes
(SC2) | SC1 | Maincode | Meaning |
0 | CMD0001 | No error | |
1 | CMD0202 | Syntax error | |
3 | CMD2203 | Incorrect syntax file | |
32 | CMD0221 | System error (internal error) | |
64 | CMD2009 | Error during S variable replacement | |
64 | CMD0216 | Do not have required privilege | |
64 | OPS0001 | No storage for S variables | |
64 | SDP0091 | Semantic error | |
64 | SDP0517 | Specified variable steam name does not exist | |
64 | SDP0519 | No match for specified wildcards |
Example
Input
/DECLARE-VARIABLE OPS-VAR(TYPE=*STRUCTURE),MULTIPLE-ELEMENTS=*LIST /ASSIGN-STREAM SYSINF,TO=*VARIABLE(OPS-VAR) /ASSIGN-SYSOUT TO=#ERROR-SYSOUT /SHOW-STREAM-ASSIGNMENT SYSINF
Output
STREAM-NAME = SYSINF ASSIGN-LEVEL = 0 DESTINATION = *VARIABLE VARIABLE-NAME = OPS-VAR VAR-MODE = *EXTEND RETURN-VARIABLE-NAME = *NONE CONTROL-VAR-NAME = *NONE RET-CONTROL-VAR-NAME = *NONE
Structured outputs
To permit structured output into variables, the following operands are supported for the SHOW-STREAM-ASSIGNMENT command:
STREAM-NAME (all values)
INFORMATION (all values)
Further details, such as for example the conditions on the usage of individual variables, will be found in the following table.
Output structure
Output information | Name of the S variable1) | T2) | Contents3) | Condition |
Procedure level | var#.ASS-LEV | I | <integer> | |
Type of list extension for | var#.CONTR-VAR-MODE | S | *EXT | CONTR-VAR-NAME |
Name of the control variable | var#.CONTR-VAR-NAME | S | *NONE | DEST= |
Output destination | var#.DEST | S | *DUMMY | |
Type of list extension for | var#.RET-CONTR-VAR-MODE | S | *EXT | CONTR-VAR-NAME |
Name of the return control | var#.RET-CONTR-VAR-NAME | S | *NONE | DEST= |
Type of list extension for | var#.RET-VAR-MODE | S | *EXT | CONTR-VAR-NAME |
Name of the return variable | var#.RET-VAR-NAME | S | *NONE | DEST= |
Server information | var#.SERVER-INFO | S | *NONE | DEST= |
Name of the server | var#.SERVER-NAME | S | <struc.-name 1..30> | DEST= |
Name of the S variable stream | var#.STREAM-NAME | S | <struc.-name 1..20> | |
Type of list extension for | var#.VAR-MODE | S | *EXT | DEST= |
Name of the S variable | var#.VAR-NAME | S | *NONE | DEST= |
1) The individual variables are arranged in alphabetical order in this table.
2) The column headed T identifies the data types: B stands for Boolean, S for string and I for Integer
3) If the condition is not true, the variable is assigned an empty string (string with length 0).