Chapter Contents |
Previous |
Next |
SAS Macro Language: Reference |
There are three types of macro expressions: text, logical, and arithmetic. A text expression is any combination of text, macro variables, macro functions, or macro calls. Text expressions are resolved to generate text. Here are some examples of text expressions:
A logical expression or an arithmetic expression is a sequence of operators and operands forming a set of instructions that are evaluated to produce a result. An arithmetic expression contains an arithmetic operator. A logical expression contains a logical operator. The following table show examples of simple arithmetic and logical expressions:
Arithmetic Expressions | Logical expressions | |
---|---|---|
1 + 2 | &DAY = FRIDAY | |
4 * 3 | A < a | |
4 / 2 | 1 < &INDEX | |
00FFx - 003Ax | &START NE &END |
The following sections tell you where and how to use arithmetic and logical expressions in macro functions and statements.
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.