BookmarkSubscribeRSS Feed
Doug____
Pyrite | Level 9

Is there a single command to do this or does each dataset have to be specified. I am running into locking issues on our server and until it is upgraded I have to put SAS to sleep (say 0.5 seconds) at certain spots in the code to avoid errors. Any helpful suggestions are welcome.

4 REPLIES 4
Reeza
Super User

I have to put SAS to sleep (say 0.5 seconds) at certain spots in the code to avoid errors

Do you have a process where tables are opening by themselves? Using EG with a process flow and tables are being shown or results?

There's an option in either way to turn off results as they're generated so that when running long programs you don't see the output until you go to it.

 

 

Astounding
PROC Star

Most data set locks are unrelated to the server.  For example:

 

  • One program is sorting a data set.  During the sorting process, another program attempts to read that data set.
  • One program is reading a data set.  During that process, another program attempts to modify that data set.

In those types of situations, there is no way to free up the locked data set until the first program is finished with it.

 

Some locking situations are environment-specific.  For example, the rules/tools for EG might be different than the rules/tools for an IBM mainframe.  A few details might help, both about the environment and about the conditions that cause locking.

Doug____
Pyrite | Level 9

The environment is Windows 7 Enterprise and I am using EG 7.15. What I am doing is remove interim datasets at the end of some data steps & SQL calls using PROC DATASETS to unclutter the project view. However, I also run into this from time to time in other areas as well. What I've done is to sort any dataset to a new dataset which seems to alleviate most of the errors.

Astounding
PROC Star

Sounds like you are doing the right thing (see the first bullet point above).  

 

The second bullet point requires a more difficult fix, as it involves analyzing (and possibly reorganizing) the order of steps in multiple processes to avoid contention for the same data set.

 

Keep fixing what you are fixing.  Upgrading to a new server will be largely ineffective, helping only to the extent that the new server can sort data sets faster than the old server.

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

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
  • 4 replies
  • 2261 views
  • 0 likes
  • 3 in conversation