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.

SAS Innovate 2025: Call for Content! Submit your proposals before Sept 16. Accepted presenters get amazing perks to attend the conference!
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 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 16. Read more here about why you should contribute and what is in it for you!

Submit your idea!

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
  • 2000 views
  • 6 likes
  • 4 in conversation