Quantcast
Channel: IBM Mainframe Computers Forums
Viewing all articles
Browse latest Browse all 8500

All Other Mainframe Topics :: RE: Reading data from PS file and send it as EMAIL body - SAS

$
0
0
Author: rajatbagga
Posted: Wed Oct 12, 2016 6:00 am (GMT 5.5)

vasanthz wrote:
This one works fine. Made changes to font.
Code:
//STEP1    EXEC SAS                                           
 //IN1      DD *                                               
 Hey I just met you                                             
 And this is crazy                                             
 But here s my number                                           
 So call me maybe                                               
 It s hard to look right at you baby                           
 But here s my number                                           
 So call me maybe                                               
 /*                                                             
 //SYSIN    DD   *                                             
 FILENAME EMAIL EMAIL                                           
  FROM = ("vasanthz@trolland.com")                   
  TO = ("vasanthz@trolland.com")                     
  REPLYTO=("vasanthz@trolland.com")                 
  SUBJECT="SOME SAMPLE TEST REPORT"                             
  CONTENT_TYPE = "text/html"                                   
 //         DD *                                               
      IMPORTANCE = "HIGH"                                       
 //         DD *                                               
 ;                                                             
data _null_;                                 
file email;                                   
infile in1 end=last;                         
INPUT;                                       
IF _N_ = 1 THEN DO;                           
  put '<html>';                               
  put '<body>';                               
  put '<pre style="font: monospace">';       
END;                                         
  put _INFILE_;                                                             
IF LAST THEN DO;                             
  put '</pre>';                               
  put '</body>';                             
  put '</html>';                             
END;                                         
run;                           


Thanks a LOT, This works perfectly well, and Yeah this is off course the test data, I have lot of other stuff which needed to be displayed one below the other in the body of the email so the alignment of data was really very important.

Now its looking all good.


Coming onto selection of SAS, Well i am reading the data and depending on the data/stat I want to email I am marking the importance of the email as IMPORTANCE = "HIGH" !! , this is not possible to achieve in the normal SMTP/IEBGENER scenario.


Thanks Again,
Regards,
Rajat


Viewing all articles
Browse latest Browse all 8500

Trending Articles