BookmarkSubscribeRSS Feed
BaileyY
Obsidian | Level 7

Hi. 

 

I am working on pc laptop with the latest SAS Base installed.  I have had errors and storage issues running large temporary work data being stored in my laptops 'c' drive.  I've written code to delete any temporary tables as I work along by inserting

'proc datasets lib=work kill nolist memtype=data;  quit;'  anywhere I can.  But my jobs are failing due to storage.  I believe there is code where I can direct the processing of my data on an external drive (with more storage) to continue on my work?  Does anyone know the code for this?   I would like this code embedded into the software so I do not have to run any macros each time I load up SAS.  Can anyone help me?  Thank you in advance

5 REPLIES 5
Kurt_Bremser
Super User

Make a copy of the configuration file used for your SAS session (with just Base installed, this should be sasv9.cfg in Program Files\SASHome\SASFoundation\9.4), and modify the -WORK directive. Then change your desktop link to use that configuration file.

Reeza
Super User
Storage or RAM?
What types of PROCS are you running? If it's Sorts, merges and such it's likely a storage issues. If it's regression or optimization, it's likely a RAM issue.

A common workaround for this is to assign a library with the name USER at the beginning of processes you know are large and need to be redirected. Then all files will go to that folder. You will want to introduce some more data management by dropping intermediary data sets if needed.

SASKiwi
PROC Star

If SAS crashes then you may be left with SAS WORK folders on your C drive that can't be cleaned up by PROC DATASETS. In Windows Explorer navigate to your SAS WORK folder, normally called SASWORK and delete any old folders named _TDnnnn_xxxxxxxx. 

Astounding
PROC Star
One additional item to consider...

Are you compressing your data? Better when you have many character variables:

options compress=yes;

Better when you have many numeric variables:

options compress=binary;
ChrisNZ
Tourmaline | Level 20

1.Even (much) better is to use SPDE tables with binary compression.

libname W spde "%sysfunc(pathname(WORK))" compress=binary partsize=1t;

Data sets are typically shrunk by at least 80%.

 

2. Also consider splitting the paths for the WORK library and for the utility files onto separate disks, using option UTILLOC.

 

 

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!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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
  • 5 replies
  • 1036 views
  • 4 likes
  • 6 in conversation