From: RolandRB on
What happens when you run this sas code on Windows 7?


%macro env2ds(dsout);

%if not %length(&dsout) %then %let dsout=_env2ds;

filename _env2ds pipe 'set';

data &dsout;
length name $ 40 value $ 1000;
infile _env2ds;
input;
name=scan(_infile_,1,"=");
value=substr(_infile_,index(_infile_,"=")+1);
label name="Environment Variable Name"
value="Environment Variable Value"
;
run;

filename _env2ds clear;

%mend;


%env2ds;
From: francogrex on
RolandRB wrote:
>What happens when you run this sas code on Windows 7?
>%macro env2ds(dsout);...<snip>

Yes it does work on windows xp (sas v9), it creates a set called _env2ds
and as expected contains 2 columns of the env variable names and values;
nice.




From: RolandRB on
On Jul 31, 10:37 am, francogrex <fra...(a)grex-removethis.com> wrote:
> RolandRB wrote:
> >What happens when you run this sas code on Windows 7?
> >%macro env2ds(dsout);...<snip>
>
> Yes it does work on windows xp (sas v9), it creates a set called _env2ds
> and as expected contains 2 columns of the env variable names and values;
> nice.

Thanks. I know it works on Windows XP. It is whether it works on
Windows 7 either 32 bit or 64 bit I need to know.
From: Uelsasser on
On 31 Jul., 10:57, RolandRB <rolandbe...(a)hotmail.com> wrote:
> On Jul 31, 10:37 am, francogrex <fra...(a)grex-removethis.com> wrote:
>
> > RolandRB wrote:
> > >What happens when you run this sas code on Windows 7?
> > >%macro env2ds(dsout);...<snip>
>
> > Yes it does work on windows xp (sas v9), it creates a set called _env2ds
> > and as expected contains 2 columns of the env variable names and values;
> > nice.
>
> Thanks. I know it works on Windows XP. It is whether it works on
> Windows 7 either 32 bit or 64 bit I need to know.

Hi Roland

it does not work on WINDOWS 7 / 32 bit , SAS V9.2
The log reads

NOTE: The infile _ENV2DS is:
Unnamed Pipe Access Device,
PROCESS=set,RECFM=V,LRECL=256

Stderr output:
Das Handle ist ungltig.
Das Handle ist ungltig.
Das Handle ist ungltig.
Das Handle ist ungltig.
Das Handle ist ungltig.
...........

From: RolandRB on
On Aug 3, 2:48 pm, Uelsasser <UlrichElsas...(a)t-online.de> wrote:
> On 31 Jul., 10:57, RolandRB <rolandbe...(a)hotmail.com> wrote:
>
> > On Jul 31, 10:37 am, francogrex <fra...(a)grex-removethis.com> wrote:
>
> > > RolandRB wrote:
> > > >What happens when you run this sas code on Windows 7?
> > > >%macro env2ds(dsout);...<snip>
>
> > > Yes it does work on windows xp (sas v9), it creates a set called _env2ds
> > > and as expected contains 2 columns of the env variable names and values;
> > > nice.
>
> > Thanks. I know it works on Windows XP. It is whether it works on
> > Windows 7 either 32 bit or 64 bit I need to know.
>
> Hi Roland
>
> it does not work on WINDOWS 7 / 32 bit , SAS V9.2
> The log reads
>
> NOTE: The infile _ENV2DS is:
>       Unnamed Pipe Access Device,
>       PROCESS=set,RECFM=V,LRECL=256
>
> Stderr output:
> Das Handle ist ung ltig.
> Das Handle ist ung ltig.
> Das Handle ist ung ltig.
> Das Handle ist ung ltig.
> Das Handle ist ung ltig.
> ..........

Thanks.