BookmarkSubscribeRSS Feed
rytch
Calcite | Level 5

Hello all members,

I would like to thank you all who are able to give me a hint or advice how to solve my current issues im facing.

My issue is regarding errror gathering to one place (variable,..).

Question is, if there exist any special variable, options settings or whatever what could help me to gather of all errors, which happened in e.g. macro.

Currently Im using system variables  &syserr and & syserrortext but i am able to handle only last error and if happened any errors before the last one, im not able to retreive information regarding it.

Thank you very much

Richard

4 REPLIES 4
SASKiwi
PROC Star

In EG 6.1 or higher, a log summary is produced which lists all of the log warnings, errors and notes - in one place.

Why try doing it for yourself when SAS has done it for you? If you don't have at least EG 6.1 you can easily request it from SAS.

rytch
Calcite | Level 5

The thing is that i have stored process where a include several files of macros. I run this stored process from external application through ws. I thought that there can be some workaround or functionallity, which could help me to return list of errors from executed macros to external application. I really would like to avoid parsing log summary :smileyshocked:

thank you

RIchard

rytch
Calcite | Level 5

The thing is that we use an external tool in cooperation with SAS database. We call through web services stored processes created in SAS EG. Stored processes contain source code with included other macro file. When we call ws, stored  process starts and if any error in macro file occur, we would like to return it to user in external tool. We are able only to catch last error and it is kind of unpleasant to return it one by one.

Thank you

Richard

SASKiwi
PROC Star

If I understand your requirements correctly then I don't think there is a generic way to trap all possible errors and return them users as a list. One possibility might be to run your stored processes with the SAS option ERRORABEND. This will cause SAS to abort when it gets an error, so you will only ever get one error with your job. The web service interface should then at least report a general failure message. Others who have used stored processes more might be able to offer further advice.  

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

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