An Idea Exchange for SAS software and services

Comments
by Trusted Advisor
on ‎02-13-2017 10:55 AM

Aren't you talking about what abort already does with the cancel argument?

 

data ...; abort cancel; run;

*or;

%abort cancel;
by PROC Star
on ‎02-13-2017 05:17 PM

This still generates an error sadly.

by Trusted Advisor
on ‎02-13-2017 06:02 PM

Seems to me like a self-created problem.  If you don't want the error message then write the program as a macro and either control your process flow with %if statements and labels or using %return when you want to stop processing...

 

 

 

by PROC Star
on ‎02-14-2017 04:22 PM

Self-created? How?

Having to embed all the code in a macro is exactly why I wrote my "kludge". Sometimes, it is just too much of a pain.

 

Having a way to stop a program from running any further without creating an error (a big no-no in production systems) does seem a very sensible, if not obvious, feature to me.

 

by Trusted Advisor
on ‎02-14-2017 05:05 PM

Don't get me wrong, I think making something like the stop statement global could be useful.  I just see many already existing alternatives which are due their merit here and are far less of a kludge (I found yours to be quite clever)

by PROC Star
on ‎02-14-2017 08:07 PM

> clever

Thank you!  Smiley Happy

 

>many already existing alternatives

There is only one way I can think of: put all the code in a huge macro that serves no other purpose than to stop the steps it contains.

Idea Statuses
Top Liked Authors