mirror of
https://github.com/sasjs/core.git
synced 2026-01-07 01:20:05 +00:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
de3610d1aa | ||
|
|
d35d597437 | ||
|
|
3e8deda008 |
38
all.sas
38
all.sas
@@ -18,24 +18,12 @@
|
|||||||
options noquotelenmax;
|
options noquotelenmax;
|
||||||
/**
|
/**
|
||||||
@file
|
@file
|
||||||
@brief abort gracefully according to context
|
@brief to be deprecated
|
||||||
@details Do not use directly! See bottom of explanation for details.
|
@details We will deprecate this macro in 2022
|
||||||
|
|
||||||
Configures an abort mechanism according to site specific policies or the
|
As you can see, it's not a macro function.
|
||||||
particulars of an environment. For instance, can stream custom
|
|
||||||
results back to the client in an STP Web App context, or completely stop
|
|
||||||
in the case of a batch run.
|
|
||||||
|
|
||||||
For the sharp eyed readers - this is no longer a macro function!! It became
|
Use mp_abort.sas instead.
|
||||||
a macro procedure during a project and now it's kinda stuck that way until
|
|
||||||
that project is updated (if it's ever updated). In the meantime we created
|
|
||||||
`mp_abort` which is just a wrapper for this one, and so we recomend you use
|
|
||||||
that for forwards compatibility reasons.
|
|
||||||
|
|
||||||
@param mac= to contain the name of the calling macro
|
|
||||||
@param type= deprecated. Not used.
|
|
||||||
@param msg= message to be returned
|
|
||||||
@param iftrue= supply a condition under which the macro should be executed.
|
|
||||||
|
|
||||||
@version 9.2
|
@version 9.2
|
||||||
@author Allan Bowe
|
@author Allan Bowe
|
||||||
@@ -3397,7 +3385,6 @@ run;
|
|||||||
@li mf_getuniquefileref.sas
|
@li mf_getuniquefileref.sas
|
||||||
@li mf_getvarlist.sas
|
@li mf_getvarlist.sas
|
||||||
@li mf_getvartype.sas
|
@li mf_getvartype.sas
|
||||||
@li mf_nobs.sas
|
|
||||||
@li mp_filtergenerate.sas
|
@li mp_filtergenerate.sas
|
||||||
@li mp_filtervalidate.sas
|
@li mp_filtervalidate.sas
|
||||||
|
|
||||||
@@ -3510,18 +3497,23 @@ data &outds;
|
|||||||
|
|
||||||
run;
|
run;
|
||||||
|
|
||||||
|
%local nobs;
|
||||||
|
%let nobs=0;
|
||||||
data _null_;
|
data _null_;
|
||||||
set &outds;
|
set &outds end=last;
|
||||||
call symputx('REASON_CD',reason_cd,'l');
|
putlog (_all_)(=);
|
||||||
stop;
|
if last then do;
|
||||||
|
call symputx('REASON_CD',reason_cd,'l');
|
||||||
|
call symputx('nobs',_n_,'l');
|
||||||
|
end;
|
||||||
run;
|
run;
|
||||||
|
|
||||||
%mp_abort(iftrue=(&abort=YES and %mf_nobs(&outds)>0),
|
%mp_abort(iftrue=(&abort=YES and &nobs>0),
|
||||||
mac=&sysmacroname,
|
mac=&sysmacroname,
|
||||||
msg=%str(Filter issues in &inds, reason: &reason_cd, details in &outds)
|
msg=%str(&nobs filter issues in &inds, reason: &reason_cd, details in &outds)
|
||||||
)
|
)
|
||||||
|
|
||||||
%if %mf_nobs(&outds)>0 %then %do;
|
%if &nobs>0 %then %do;
|
||||||
%let syscc=1008;
|
%let syscc=1008;
|
||||||
%return;
|
%return;
|
||||||
%end;
|
%end;
|
||||||
|
|||||||
@@ -1,23 +1,11 @@
|
|||||||
/**
|
/**
|
||||||
@file
|
@file
|
||||||
@brief abort gracefully according to context
|
@brief to be deprecated
|
||||||
@details Do not use directly! See bottom of explanation for details.
|
@details We will deprecate this macro in 2022
|
||||||
|
|
||||||
Configures an abort mechanism according to site specific policies or the
|
As you can see, it's not a macro function.
|
||||||
particulars of an environment. For instance, can stream custom
|
|
||||||
results back to the client in an STP Web App context, or completely stop
|
|
||||||
in the case of a batch run.
|
|
||||||
|
|
||||||
For the sharp eyed readers - this is no longer a macro function!! It became
|
Use mp_abort.sas instead.
|
||||||
a macro procedure during a project and now it's kinda stuck that way until
|
|
||||||
that project is updated (if it's ever updated). In the meantime we created
|
|
||||||
`mp_abort` which is just a wrapper for this one, and so we recomend you use
|
|
||||||
that for forwards compatibility reasons.
|
|
||||||
|
|
||||||
@param mac= to contain the name of the calling macro
|
|
||||||
@param type= deprecated. Not used.
|
|
||||||
@param msg= message to be returned
|
|
||||||
@param iftrue= supply a condition under which the macro should be executed.
|
|
||||||
|
|
||||||
@version 9.2
|
@version 9.2
|
||||||
@author Allan Bowe
|
@author Allan Bowe
|
||||||
|
|||||||
@@ -45,7 +45,6 @@
|
|||||||
@li mf_getuniquefileref.sas
|
@li mf_getuniquefileref.sas
|
||||||
@li mf_getvarlist.sas
|
@li mf_getvarlist.sas
|
||||||
@li mf_getvartype.sas
|
@li mf_getvartype.sas
|
||||||
@li mf_nobs.sas
|
|
||||||
@li mp_filtergenerate.sas
|
@li mp_filtergenerate.sas
|
||||||
@li mp_filtervalidate.sas
|
@li mp_filtervalidate.sas
|
||||||
|
|
||||||
@@ -158,18 +157,23 @@ data &outds;
|
|||||||
|
|
||||||
run;
|
run;
|
||||||
|
|
||||||
|
%local nobs;
|
||||||
|
%let nobs=0;
|
||||||
data _null_;
|
data _null_;
|
||||||
set &outds;
|
set &outds end=last;
|
||||||
call symputx('REASON_CD',reason_cd,'l');
|
putlog (_all_)(=);
|
||||||
stop;
|
if last then do;
|
||||||
|
call symputx('REASON_CD',reason_cd,'l');
|
||||||
|
call symputx('nobs',_n_,'l');
|
||||||
|
end;
|
||||||
run;
|
run;
|
||||||
|
|
||||||
%mp_abort(iftrue=(&abort=YES and %mf_nobs(&outds)>0),
|
%mp_abort(iftrue=(&abort=YES and &nobs>0),
|
||||||
mac=&sysmacroname,
|
mac=&sysmacroname,
|
||||||
msg=%str(Filter issues in &inds, reason: &reason_cd, details in &outds)
|
msg=%str(&nobs filter issues in &inds, reason: &reason_cd, details in &outds)
|
||||||
)
|
)
|
||||||
|
|
||||||
%if %mf_nobs(&outds)>0 %then %do;
|
%if &nobs>0 %then %do;
|
||||||
%let syscc=1008;
|
%let syscc=1008;
|
||||||
%return;
|
%return;
|
||||||
%end;
|
%end;
|
||||||
|
|||||||
Reference in New Issue
Block a user