BookmarkSubscribeRSS Feed
Peet
Calcite | Level 5

I am using SAS/ML Studio and loading the program as said:

/***********************************************/
/* In the line of code below, replace FILEPATH */
/* with the path to your EPG194/data folder */
/***********************************************/

%let path=C:\Program Files\SASHome\EPG194\data;

/**********************************************/
/* DO NOT EDIT THE CODE BELOW */
/**********************************************/

libname PG1 "&path";

 

It runs successfully with the following:

NOTE: Libref PG1 was successfully assigned as follows:
Engine: V9
Physical Name: C:\Program Files\SASHome\EPG194\data
15

but when i run the createdata programe the path is not the one i specified :

error message i am getting:

WARNING: Physical file does not exist, C:\WINDOWS\system32\&path\_1create_class.sas.

it does not default to the path specified, I am new to SAS am i overlooking something ?

 

Thanks

5 REPLIES 5
andreas_lds
Jade | Level 19

Posting the code/log causing the error would be useful to help you.

Peet
Calcite | Level 5

Hi there apology, here is the full log

 

NOTE: Copyright (c) 2002-2012 by SAS Institute Inc., Cary, NC, USA.
NOTE: SAS (r) Proprietary Software 9.4 (TS1M3)
Licensed to IQ BUSINESS PARTNER, Site 70210183.
NOTE: This session is executing on the X64_8PRO platform.

 

NOTE: Updated analytical products:

SAS/STAT 14.1
SAS/ETS 14.1
SAS/OR 14.1
SAS/IML 14.1

NOTE: Additional host information:

X64_8PRO WIN 6.2.9200 Workstation

NOTE: SAS Initialization used (Total process time):
real time 0.03 seconds
cpu time 0.03 seconds

3
4 /**********************************************/
5 /* You must run SETUP.SAS before you run */
6 /* this code to create your data for EPG194 */
WARNING: Apparent symbolic reference PATH not resolved.
7 /* */
8 /* DO NOT EDIT THE CODE BELOW */
9 /**********************************************/
10
11 %include "&path/_1create_class.sas";
WARNING: Physical file does not exist, C:\WINDOWS\system32\&path\_1create_class.sas.
ERROR: Cannot open %INCLUDE file &path/_1create_class.sas.
WARNING: Apparent symbolic reference PATH not resolved.
12 %include "&path/_2create_natpark.sas";
WARNING: Physical file does not exist, C:\WINDOWS\system32\&path\_2create_natpark.sas.
ERROR: Cannot open %INCLUDE file &path/_2create_natpark.sas.
WARNING: Apparent symbolic reference PATH not resolved.
13 %include "&path/_3create_storm.sas";
WARNING: Physical file does not exist, C:\WINDOWS\system32\&path\_3create_storm.sas.
ERROR: Cannot open %INCLUDE file &path/_3create_storm.sas.
14
15 proc contents data=pg1._all_ nods;
16 run;

ERROR: Libref PG1 is not assigned.
NOTE: Statements not processed because of errors noted above.
NOTE: PROCEDURE CONTENTS used (Total process time):
real time 0.01 seconds
cpu time 0.01 seconds

NOTE: The SAS System stopped processing this step because of errors.
17
18 ;*';*";*/;

andreas_lds
Jade | Level 19

The macro-variable path is not defined in the program you have posted. The log has the following warning:

WARNING: Apparent symbolic reference PATH not resolved.

 

Peet
Calcite | Level 5

Thank you for the fast reply.

 

As i said new to SAS, how would i then fix this ? as the first thing we are told to do is the below:

/***********************************************/
/* In the line of code below, replace FILEPATH */
/* with the path to your EPG194/data folder */
/***********************************************/

%let path=C:\Program Files\SASHome\EPG194\data;

/**********************************************/
/* DO NOT EDIT THE CODE BELOW */
/**********************************************/

libname PG1 "&path";

 

Thank you

andreas_lds
Jade | Level 19

You have to execute that part of code each time you start a new session and want to use the variable "path".

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

How to connect to databases in SAS Viya

Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 5 replies
  • 3367 views
  • 1 like
  • 2 in conversation