BookmarkSubscribeRSS Feed
EinarRoed
Pyrite | Level 9

I've got a large SAS-program with many data steps. I'm running it in EG 8.3.

 

If for example the 77th data step fails, then the results of all the previous 76 data steps are lost, and connection to the server is lost. So I need to reconnect and rerun all the data steps to get back to where I was.

 

Is there any way to prevent this? If the 77th data step fails, I don't want to lose all my progress and disconnect. I want it to be an isolated failure, so that I can just fix and rerun that particular data step.

3 REPLIES 3
ChrisHemedinger
Community Manager

EG should not disconnect just because a step fails with an error. If the step causes a severe failure (a crash in SAS), then that's a bug in SAS -- which may have a workaround or may require a fix. A crash would cause SAS to disconnect, since it terminates the SAS process. If that's what happens then you should try to capture the SAS log for that step and report to SAS Technical Support.

Check out SAS Innovate on-demand content! Watch the main stage sessions, keynotes, and over 20 technical breakout sessions!
ballardw
Super User

@EinarRoed wrote:

I've got a large SAS-program with many data steps. I'm running it in EG 8.3.

 

If for example the 77th data step fails, then the results of all the previous 76 data steps are lost, and connection to the server is lost. So I need to reconnect and rerun all the data steps to get back to where I was.

 

Is there any way to prevent this? If the 77th data step fails, I don't want to lose all my progress and disconnect. I want it to be an isolated failure, so that I can just fix and rerun that particular data step.


If you want data sets to persist then place them in a library you define. The highlighted behavior indicates to me that the sets are being written to the WORK library. Even if a program fails data sets in other libraries would not be "lost". You would just make sure the library was assigned in a another session and they would be there.

 

By any chance have you, or your SAS Admin, set the system option ERRORABEND? That could terminate a SAS session when an error is encountered.

SASKiwi
PROC Star

Setting the SAS option ERRORABEND causes the behaviour you are seeing. Check the setting in your SAS session by running this:

proc options option = errorabend;
run;

If it is set then add this at the top of your program to turn it off:

options noerrorabend;

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!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

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