NET/MASTER Network Control Language (NCL) Reference Manual
9 Variables
106126 Tandem Computers Incorporated 9–1
This section describes variables. It includes the following topics:
An overview of variables
The syntax rules for naming variables
Variable name-substitution rules
Variables by function
Assigning values to variables by using the assignment statement
For help in understanding syntax notation, see “Notation Conventions” at the
beginning of this manual.
Note This section does not discuss mapped data object (MDO) variables in detail. These are discussed in the
NonStop NET/MASTER NCL Programmer’s Guide.
An Overview of
Variables
This subsection includes discussion of the following topics:
The variable character set
The maximum data length for a variable
The maximum variable name length
How variables store data
The Variable Character Set A variable is a lexical element that stores data that can change during the execution of
an NCL process. You refer to a variable by an ampersand (&) followed by one or more
of the characters in Table 9-1.
Table 9-1. Variable Characters
Character Name of Character You Can Use It in
A–Z, a–z Letters All variables, letters are case-insensitive.
0–9 Digits All variables, in restricted positions.
_ Underscore All variables.
@ At sign All variables.
# Number sign All variables.
$ Dollar sign All variables.
& Ampersand Complex and nested variables only.
. Period Stem and compound variables only.
( ) Parentheses Nested variables only.
{ } Braces All variables, in restricted positions.
This set of characters is the complete set of valid variable name characters. Particular
variable types restrict the characters they allow and the position in which they allow
them; these restrictions are covered later in this section in “Variable Name Syntax.”