DATA Step, Macro, Functions and more

WARNING: EMAIL: 552 MAIL FILE TOO LARGE

Reply
Frequent Contributor
Posts: 78

WARNING: EMAIL: 552 MAIL FILE TOO LARGE

On MVS while attaching file it's too large and get above error now what I like to do is fetch this error and notify via email...i tried with SYSERR however that doesn't seems to work out..anybody else got any other thoughts?

Respected Advisor
Posts: 3,887

Re: WARNING: EMAIL: 552 MAIL FILE TOO LARGE

Looks like a Warning and not an Error to me.

 

Not sure if this will work but you could try to check for a return code of "warning" and if there is one also check the content of automatic macro variable "&SYSWARNINGTEXT" (=does it contain the expected warning). Send an email if both conditions are satisfied.

SAS Employee
Posts: 24

Re: WARNING: EMAIL: 552 MAIL FILE TOO LARGE

I hope this little program helps:

 

/*if the commented set statement is used instead of the
uncommented set statement in the second data step below,
the value of &syscc will be non-zero for the program, and
the value of &syserr will be non-zero for the step. You can
see in the log that the value of &syserr will change for each
step and the value of &syscc will not.
*/
options mprint symbolgen;
%macro conditionally;
data test;
x=4;
run;
data foo;
set test;
/*set nolib.nodata;*/
if x=2 then delete;
run;
%put &syscc;/*this macro value returns a non-zero for the program
if there is any message other than a NOTE*/
%put &syserr;/*this macro value returns a non-zero for the step
of the program*/
%if &syserr ne 0 %then %do;
%put 'ERROR in DATA Step';
%end;
%else %do;
proc print;
run;
%end;
data one;x=0;run;
%put &syserr;
%put &syscc;
%mend;

%conditionally;
run;

Ask a Question
Discussion stats
  • 2 replies
  • 326 views
  • 0 likes
  • 3 in conversation