BookmarkSubscribeRSS Feed
WesBarris
Obsidian | Level 7
I have encountered a strange error. I am using the following code to read filenames that match a given pattern:

filename DIR pipe "dir /B c:\thisdir\abc123*.dat";
data dirlist;
length file $20;
infile DIR length=reclen;
input file $varying20. reclen;
run;

When I run this code everything works as expected. When one of my colleges runs this same code from his account, he gets this error:

NOTE: The infile DIR is:
Unnamed Pipe Access Device,
PROCESS=dir /B c:\thisdir\abc123*.dat,RECFM=V,
LRECL=256

Stderr output:
There is not enough space on the disk.
NOTE: 0 records were read from the infile DIR.
NOTE: The data set WORK.DIRLIST has 0 observations and 1 variables.

There is plenty of disk space on all disks. So, this error is more likely the result of a permission problem, but where? Does anyone have any ideas?
2 REPLIES 2
WesBarris
Obsidian | Level 7
Pardon me for replying to my own question but I have some more information to add.

If I start sas by double clicking on a sas icon pinned to the startmenu or taskbar
the following code works:

filename DIR pipe "dir /B";
data dirlist ;
length file $20;
infile DIR length=reclen;
input file $varying20. reclen;
run;
proc print data = dirlist;
run;

However, if I start sas by clicking on "Start -> All Programs -> SAS -> SAS 9.2 (English) that same code results in this error:

NOTE: The infile DIR is:
Unnamed Pipe Access Device,
PROCESS=dir /B,RECFM=V,LRECL=256

Stderr output:
There is not enough space on the disk.
NOTE: 0 records were read from the infile DIR.

I am at a loss to figure out why. Both shortcuts seem to be set up identically. If I
drag the SAS shortcut that was pinned to the startmenu to the desktop and start SAS from that, it fails with the error.

We are running SAS 9.2 on Windows Server 2008. I need to understand the reason for this error so that I can modify the code to run no matter how sas is started.

Thanks.
data_null__
Jade | Level 19
See if this is related to your problem

http://support.sas.com/kb/41/863.html

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

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
  • 2 replies
  • 5387 views
  • 0 likes
  • 2 in conversation