- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hi
How do I stop SAS when it encounters an error. Just want it to stop processing, not terminate the session (Abend).
By simply stopping I can then still have the work datasets and log available to look for the cause.
Is there an Option for this
Thanks in advance
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
One option is to run the code via a wrapper, i.e. wrap the code within a macro, check for errors, and determine whether the next step will run based on the error codes.
E.g., take a look at: http://www2.sas.com/proceedings/sugi30/021-30.pdf
It shows the method for running in batch but, at the end, also shows how to set it up to run interactively.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Check what your options are:
proc options group=ERRORHANDLING; run;
specificly look into ERRORABEND/NOERRORABEND, ERRORBYABEND/NOERRORBYABEND
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Thanks Guys
Will look into them and post back
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
If you are using SAS interactively, look at OPTIONS DMSSYNCHK. Be warned that SAS broke that a little bit in 9.2 as compared to 9.1.3. I don't know if they repaired it in 9.3. In 9.1.3 if you hit an error with DMSSYNCHK on it would stop subesquent steps that had already been submitted from running but would still allow you to resubmit without problems. In 9.2 if you hit an error with DMSSYNCHK you seem to have to restart SAS to get out of that error state. Still, even if you are stuck in that state you can still look at your datasets, logs, etc.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
I could not find the answer I was looking for.
I have flows build in DI studio, when I run the generated .sas code in batch I want the batch job to stop when/if the first error occurs.
Any idea's?