BookmarkSubscribeRSS Feed
CamRutherford
Fluorite | Level 6

Hello,

 

I have the below code whereby I'm trying to import multiple .csv file types from a network folder. I access SAS through citrix reciever.

 

DATA TEST;
INFILE '\\CLIENT\O$\EUROMKTG\MARKETING ANALYTICS DEPT\CAMPAIGN REPORTING\TEST\CLICKS.CSV';
PROC IMPORT OUT= WORK.NEWDATA
DATAFILE='\\CLIENT\O$\EUROMKTG\MARKETING ANALYTICS DEPT\CAMPAIGN REPORTING\TEST\CLICKS.CSV';
RUN;

Please can anyone help?

6 REPLIES 6
RW9
Diamond | Level 26 RW9
Diamond | Level 26

What is the question?

 

If you lack the correct network path name, speak with your IT.

Tom
Super User Tom
Super User

You should be able to access files using that notation, IF the SAS process itself is also running on the Citrix server.  

 

If your SAS process is actually running on a Unix server (or even just a different Windows server) then it will know nothing about the mapping of virtural windows drives to folders on the Citrix user's PC.  In that case first upload the file to a location that can be access from the SAS server.

AlanC
Barite | Level 11
You are completely messing up SAS code here regardless of the path issue (possible). You have a PROC inside of a DATA step. They are 2 completely different step type boundaries. Use the PROC code only for now.

PROC IMPORT OUT= WORK.NEWDATA
DATAFILE='\\CLIENT\O$\EUROMKTG\MARKETING ANALYTICS DEPT\CAMPAIGN REPORTING\TEST\CLICKS.CSV';
RUN;

And work on that.
https://github.com/savian-net
CamRutherford
Fluorite | Level 6

I get the following error message...


ERROR: Physical file does not exist, /opt/sasconfig/grd/Lev1/SASApp/O:\EUROMKTG\MARKETING ANALYTICS DEPT\CAMPAIGN REPORTING\4. Q2
REPORTING\TEST\CLICKS.CSV.

AlanC
Barite | Level 11
Notice that you have your physical locations intertwined (O: with backslahes and network path with forward slashes). Unix and PC syntaxes mixed together.
https://github.com/savian-net
Tom
Super User Tom
Super User

@CamRutherford wrote:

I get the following error message...


ERROR: Physical file does not exist, /opt/sasconfig/grd/Lev1/SASApp/O:\EUROMKTG\MARKETING ANALYTICS DEPT\CAMPAIGN REPORTING\4. Q2
REPORTING\TEST\CLICKS.CSV.


From that error message it is easy to see that your SAS session is running on Unix and not Windows. So any path that uses drive letters will not work.  You either ask your networking to have the file share that you have mapped to the O: drive on your Windows machine mounted somewhere on the Unix servers that SAS is using. Or just copy the file somewhere first and import the copy.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 6 replies
  • 3590 views
  • 1 like
  • 4 in conversation