Problem Note 1011: Macro invocations containing concatenated macro variables do not resolve
properly
Consider the following example:
%let a=abc;
%macro readabc;
%put testing;
%mend readabc;
%read&a
In Version 6 and 7 the trailing &a would resolve before trying to
invoke the macro but this was incorrect. To be compatible with release
5.18, Version 8 tries to invoke the macro before resolving the macro
variable 'a' above.
The workaround to emulate the Version 6 and 7 behavior requires use of
the %UNQUOTE and %NRSTR functions as demonstrated below.
%let a=abc;
%macro readabc;
%put testing;
%mend readabc;
%unquote(%nrstr(%read)&a)
Due to customer feedback, the V6 behavior will be reinstated for release
8.2.
A Technical Support hot fix for Release 8.1 TSLEVEL TS1M0 for this
issue is available at:
http://www.sas.com/techsup/download/hotfix/81_sbcs_prod_list.html#001011
This problem is also fixed in Release 8.2.
Operating System and Release Information
| Product Family | Product | System | Reported Release | Fixed Release* |
| SAS System | Base SAS | Microsoft Windows 95/98 | 8 TS M0 | 8.2 TS2M0 |
| Microsoft Windows NT Workstation | 8 TS M0 | 8.2 TS2M0 |
| OpenVMS VAX | 8 TS M0 | 8.2 TS2M0 |
| Solaris | 8 TS M0 | 8.2 TS2M0 |
| IRIX | 8 TS M0 | 8.2 TS2M0 |
| 64-bit Enabled Solaris | 8 TS M0 | 8.2 TS2M0 |
| OS/2 | 8 TS M0 | 8.2 TS2M0 |
| ABI+ for Intel Architecture | 8 TS M0 | 8.2 TS2M0 |
| z/OS | 8 TS M0 | 8.2 TS2M0 |
| HP-UX | 8 TS M0 | 8.2 TS2M0 |
| OpenVMS Alpha | 8 TS M0 | 8.2 TS2M0 |
| CMS | 8 TS M0 | 8.2 TS2M0 |
| 64-bit Enabled HP-UX | 8 TS M0 | 8.2 TS2M0 |
| Tru64 UNIX | 8 TS M0 | 8.2 TS2M0 |
| 64-bit Enabled AIX | 8 TS M0 | 8.2 TS2M0 |
| AIX | 8 TS M0 | 8.2 TS2M0 |
*
For software releases that are not yet generally available, the Fixed
Release is the software release in which the problem is planned to be
fixed.
| Type: | Problem Note |
| Priority: | |
| Topic: | SAS Reference ==> Macro
|
| Date Modified: | 2002-05-14 14:40:38 |
| Date Created: | 1999-08-02 00:00:00 |