SAS Component Language Dictionary |
Return the value stored in a macro variable
-
cval
-
contains the character value returned
by SYMGET.
Type: Character
-
nval
-
contains the numeric value returned
by SYMGETN.
Type: Numeric
-
macro-var
-
is the macro variable.
Type: Character
SYMGET and SYMGETN return values of macro
variables when the program executes, whereas "¯o-var" returns values when the program compiles. SYMGET returns
the value of a SAS macro variable as a character value and SYMGETN returns
the value as a numeric value.
Execute commands if the operating system
is Windows:
if symget('SYSSCP') = 'WIN' then do;
rc = optsetn('xwait',0);
rc = optsetn('xsync',0);
end;
Return the value of the macro variable
UNIT at program execution time:
nval=symgetn('unit');
Return the values of the macro variables
UNIT and SYSJOBID at program compile time:
nval=&unit;
cval="&sysjobid";
SYMPUT and SYMPUTN
Copyright © 2009 by SAS Institute Inc., Cary, NC, USA. All rights reserved.