Appendix 2
SAS Macro Facility Error and
Warning Messages
SAS Macro Error Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 391
SAS Macro Warning Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 427
SAS Macro Error Messages
This section contains error messages that might be reported when using macros and the
solutions to correct them. If you are unable to resolve the error, then contact SAS
Technical Support.
Error: %EVAL must be followed by an expression enclosed in
parentheses.
Cause Solution
There is no expression following the %EVAL
function.
The %EVAL function must be followed by an
expression that is enclosed in parentheses .
An expression follows the %EVAL function
but the parentheses are missing.
The %EVAL function must contain an
expression that is enclosed in parentheses.
Error: Expecting a variable name after value.
Cause Solution
The first letter of the variable name begins
with a number or special character.
The first character must begin with an English
letter or an underscore. Subsequent characters
can be English letters, digits, or underscores.
The variable name is missing. Verify that the variable name exists.
Error: Symbolic variable name value must be 32 or fewer characters
long.
391
Cause Solution
The macro variable name is longer than 32
characters.
A macro variable name can be only 32
characters or less.
Error: Symbolic variable name value must begin with a letter or
underscore.
Cause Solution
The macro variable name contained within
quotation marks in the first argument to the
SYMPUT routine or the SYMPUTX routine
begins with a number or special character.
The macro variable name must begin with a
letter or an underscore.
The value of the SAS data set variable that is
used to create the macro variable name begins
with a number or special character.
The value within the data set variable must
begin with a letter or underscore.
Error: Symbolic variable name value must contain only letters,
digits, and underscores.
Cause Solution
The macro variable name contained within
quotation marks in the first argument to the
SYMPUT routine or the SYMPUTX routine
contains a special character.
The macro variable name must contain only
letters, digits, or underscores.
The value of the SAS data set variable that is
used to create the macro variable name within
the SYMPUT routine or the SYMPUTX
routine contains a special character.
The value within the data set variable must
contain only letters, digits, or underscores.
Error: Expected open parenthesis after macro function name not
found.
Cause Solution
The macro function being used is missing the
open parenthesis to begin the argument.
Each macro function used must contain an
open and close parenthesis.
Error: Maximum level of nesting of macro functions exceeded.
Cause Solution
The macro functions are nested more than ten
times.
You cannot nest macro functions more than
ten times.
392 Appendix 2 SAS Macro Facility Error and Warning Messages

Get SAS 9.4 Macro Language, 5th Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.