|
In article <08f6992b.c11fc62a@usw-ex0107-043.remarq.com>,
Walter Smith <wjsmith1NOwjSPAM@fedex.com.invalid> wrote:
<...delete...>
>
> But for me, its just a little plainer to skip the symget call and
write:
> data whatever;
> %do i = 1 %to 100;
> var&i = "sg&i";
> %end;
> run;
symget("sg1") and var1=&sg1 could be 'different'. The former requires
the macro variable available in 'excuting time', the latter needs the
macro variable available at 'compiling time'.
Just my $0.02.
NOTE: AUTOEXEC processing completed.
1 data _null_;
2 var1=symget("sg1");
3 run cancel;
NOTE: Data step not executed at user's request.
NOTE: DATA statement used:
real time 0.06 seconds
cpu time 0.00 seconds
4
5 data _null_;
6 var1=&sg1;
-
386
WARNING: Apparent symbolic reference SG1 not resolved.
7 run cancel;
ERROR 386-185: Expecting an arithmetic expression.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: DATA statement used:
real time 0.74 seconds
cpu time 0.01 seconds
Sent via Deja.com http://www.deja.com/
Before you buy.
|