Usage Note 51875: Syntax for using the EXPANDMACROS option with the SCAPROC procedure
To receive the correct results when using the EXPANDMACROS option in the RECORD statement in the SCAPROC procedure and using a macro (%MACRO code), the PROC SCAPROC code must be outside of the %MACRO code. If the PROC SCAPROC code is inside the %MACRO code, the EXPANDMACROS option is not honored.
Here is an example of using PROC SCAPROC code with the EXPANDMACROS option in the RECORD statement with %MACRO code:
proc scaproc;
record 'c:\log1.txt' expandmacros;
run;
%macro testit;
%do i=1 %to 3;
data a&i;
do i = 1 to 10;
j = cos(i);
output;
end;
run;
proc print data=a&i;
run;
proc means data=a&i;
run;
%end;
%mend testit;
%testit;
proc scaproc;
write;
run;
Operating System and Release Information
| SAS System | Base SAS | Z64 | 9.3 TS1M0 | |
| Microsoft® Windows® for x64 | 9.3 TS1M0 | |
| Microsoft Windows Server 2003 Datacenter Edition | 9.3 TS1M0 | |
| Microsoft Windows Server 2003 Enterprise Edition | 9.3 TS1M0 | |
| Microsoft Windows Server 2003 Standard Edition | 9.3 TS1M0 | |
| Microsoft Windows Server 2003 for x64 | 9.3 TS1M0 | |
| Microsoft Windows Server 2008 | 9.3 TS1M0 | |
| Microsoft Windows Server 2008 R2 | 9.3 TS1M0 | |
| Microsoft Windows Server 2008 for x64 | 9.3 TS1M0 | |
| Microsoft Windows XP Professional | 9.3 TS1M0 | |
| Windows 7 Enterprise 32 bit | 9.3 TS1M0 | |
| Windows 7 Enterprise x64 | 9.3 TS1M0 | |
| Windows 7 Home Premium 32 bit | 9.3 TS1M0 | |
| Windows 7 Home Premium x64 | 9.3 TS1M0 | |
| Windows 7 Professional 32 bit | 9.3 TS1M0 | |
| Windows 7 Professional x64 | 9.3 TS1M0 | |
| Windows 7 Ultimate 32 bit | 9.3 TS1M0 | |
| Windows 7 Ultimate x64 | 9.3 TS1M0 | |
| Windows Vista | 9.3 TS1M0 | |
| Windows Vista for x64 | 9.3 TS1M0 | |
| 64-bit Enabled AIX | 9.3 TS1M0 | |
| 64-bit Enabled HP-UX | 9.3 TS1M0 | |
| 64-bit Enabled Solaris | 9.3 TS1M0 | |
| HP-UX IPF | 9.3 TS1M0 | |
| Linux | 9.3 TS1M0 | |
| Linux for x64 | 9.3 TS1M0 | |
| Solaris for x64 | 9.3 TS1M0 | |
*
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: | Usage Note |
| Priority: | |
| Topic: | SAS Reference ==> Procedures ==> SCAPROC
|
| Date Modified: | 2013-12-20 15:53:07 |
| Date Created: | 2013-12-18 15:29:18 |