The SYMPUTN routine
assigns a numeric value to a global SAS macro variable. SYMPUTN assigns
the value when the SCL program executes. You can also use SYMPUTN
to assign the value of a macro variable whose name is stored in an
SCL variable. For example, to assign the value of SCL variable UNITNUM
to SCL variable UNITVAR, which contains 'UNIT', submit the following:
call symputn(unitvar,unitnum)
You must use SYMPUTN
with a CALL statement.
Note: It is inefficient to use
an ampersand (
&
) to reference a macro
variable that was created with CALL SYMPUTN. Instead, use SYMGETN.
It is also inefficient to use CALL SYMPUTN to store a variable that
does not contain a numeric value.