Sending e-mail thru SAS


    Sponsored Links


  • 1. Vacancies
    Mainframe Operators and Performance and Capacity Specialist required. Johannesburg, South Africa Contact: XXXX@XXXXX.COM
  • 2. enhancing the kaplan meier plot
    Hi all :) I have a kaplan meier plot stratified by 5 categories. I would like to be able to: 1) label each of the curves on the plot itself 2) add a legend to one of the corners 3) add 95% confidence intervals 4) add logrank test result to the plot 5) control the curve colors? I'd appreciate any clues to any of the above :) Thanks very much :) Hala
  • 3. Project explorer - Code Icon blues
    Hi, In EG when I run a code ("Code 3") then in the tree another version of Code 3 gets created and am not able to understand as to whats happening. Morever, I see that many times these newer versions have the code icon (Running boy) in the tree. These newer versions have the icon sometimes same as the original code's icon but again some of these versions also have a red cross on top-left of icon and sometimes they have a shortcut key sign (as in the Windows shortcut key sign) on bottom-left (this might be coming because Iam trying to store my code outside of the EG project). Whats the significance of these different kinds of icons? How do i find out which is my original code. Presently am forced to do a line-by line compare of each copy and delete all but one. Am sure am missing something very basc here. Please guide me. Regards, HP India
  • 4. New to GMAP- zip code question
    Hello all, I am new to PROC GMAP and wanted to find ways to use this "new toy" at work. One of the projects I want to do is to find the location of the staff (based on their zip codes) and produce a map that would show concentrations of staff around the location of the corporate headquarters. From what I've begun to read, this is not a simple or necessarily accurate distribution. If also, I would also like to add distance rings from headquarters out. Can anyone guide me to any previously written papers that show this type of map? Thanks Paula

Sending e-mail thru SAS

Postby » Fri, 01 Aug 2008 21:43:11 GMT


I want to send e-mail thru SAS, but my outlook is not configured in
I do want to send the mail with out configuring the outlook, is there
any way?

Please give the setting needed in the SAS.

I'm successful with the computer where the MS Outlook is configured.

Thanks in advance.

Sukumar Baluswamy

Re: Sending e-mail thru SAS

Postby anindya.lugbang » Fri, 01 Aug 2008 22:01:46 GMT

filename mymail email from="<your email id>"
                      to="<to email id>"
                      subject="Put Subject Here"
                      content_type="text/html" emailsys=smtp
emailid="logon id" emailpw="password";
data _null_;
   file mymail;
   put 'hello world';

On Thu, Jul 31, 2008 at 6:13 PM,  XXXX@XXXXX.COM 

Re: Sending e-mail thru SAS

Postby anindya.lugbang » Fri, 01 Aug 2008 22:04:21 GMT

More info -  http://www.**--****.com/ 

On Thu, Jul 31, 2008 at 6:31 PM, Anindya Mozumdar

Similar Threads:

1.Sending email from and to SUGI-mail account

Hi friends,

I just tested sending email from my SUGI account ( XXXX@XXXXX.COM ) to my home one again and now it worked! So the accounts are reachable from and to outside. But a testmail to SAS-L failed as I am not subscribed with that account.

Regards from an overwhelming impressive conference - Jim.

2.Formatting email body when sending email from a z/OS system

All information in and attached to the e-mail(s) below may be =
proprietary, confidential, privileged and otherwise protected from =
improper or erroneous disclosure.  If you are not the sender's intended =
recipient, you are not authorized to intercept, read, print, retain, =
copy, forward, or disseminate this message.  If you have erroneously =
received this communication, please notify the sender immediately by =
phone (704-758-1000) or by e-mail and destroy all copies of this message =
(electronic, paper, or otherwise).  Thank you.

I am having an issue when I send emails from my z/OS system using PUTs
in a DATA step.  My file definition is
FILENAME techserv EMAIL                                          =20
         TYPE=3D'text/html'                                        =20
         TO=3D(' XXXX@XXXXX.COM '                               =20
            )                                                    =20
         FROM=3D' XXXX@XXXXX.COM '                              =20
         SUBJECT=3D"Jobs running high CPU compared to Wall Clock"  =20
         ;                                                       =20

And my DATA step looks like
DATA _NULL_ ;                                                    =20
  FILE techserv ;                                                =20
  PUT "This is a list of jobs with programs that should be   ";  =20
  PUT "investigated.                                         ";  =20
  PUT "                                                      ";  =20
  PUT ;                                                          =20
  PUT "The programs in the jobs are running at least         ";  =20
  PUT "&display_wall. hours and are consuming at least       ";  =20
  PUT "&display_pct. CPU of a single engine.                 ";  =20
  PUT "                                                      ";  =20
  PUT ;                                                          =20

But the email message body looks like
This is a list of jobs with programs that should be investigated. The
programs in the jobs are running at least 0:15 hours and are consuming
at least 80% CPU of a single engine.

Can someone tell me what I'm doing wrong and point me to where I can
learn more?

Jim Horne
ITE-Large Systems & Messaging
Lowe's Companies, Inc.

3.Send e-mail through SAS and REXX.

Hi SAS'ers 

        I wish to send e-mail through SAS. So, i developed a REXX
Panel where i can supply all the Mail-ids and the Message. Now through
SYSPARM, i am not able to pass all addresses because it has a
restriction that we can only pass upto some maximum length through a

So finally decided that, let Rexx program write all the the Id's and
the Message to a Output File so that this can be used as an Input to
my SAS program in the next JCL Step.  So i came up with a SAS program
like below that reads the file.

Input File containing the Id's and Messages: 

Hello dear, 
        Pls help me to succeed in sending mails to 
my dear ones through SAS; 

So, all the string appearing inbetween the lines To: and CC: needs to
be concatenated into another new field say, TOIDS. Same way for the
another fields CCIDS. But for messages, i will save each line in one
temporay variable until EOF.
In Rexx,, its quite easy to implement the above logic, but is it
possible to do the same way in SAS.

The SAS Program follows here, but i'm not able to run it

  %LET array todata (5) $ todata1-todata5;        /*Unable to declare
Arrays  globally, it gives error */
  %LET array ccdata (4) $ ccdata1-ccdata4;        /*Unable to declare
Arrays  globally, it gives error */
  %LET array msgdata (2) $ msgdata1-msgdata2;      /*Unable to declare
Arrays  globally, it gives error */
 data r ;
  retain i 1; 
  retain j 1; 
  retain k 1; 
  retain type 1; 
  infile mailfile; 
  input   inrec;       
  if inrec = 'To' then  type = 1; 
  else if inrec = 'CC' then type = 2;   
  else if inrec = 'Message' then type = 3;
  if type = 1 and inrec NE 'To' then;         
        todata (i) = inrec;
else if type = 2 and inrec NE 'CC' then; 
        todata (j) = inrec;
else if type = 3  then 
              msgdata(k) = inrec; 
data getarr;  /*The arrays todata(), ccdata() and msgdata() should be
accessible here*/
RETAIN TOIDS _CHARACTER_;  /*How to initialize it here, since this is
a variable length*/
RETAIN CCIDS _CHARACTER_; /*How to initialize it here, since this is a
variable length*/
do i= 1 to 5; 
   TOIDS =  TOIDS || ' ' || todata(i); 
TOIDS = strip(TOIDS); 
do j= 1 to 4; 
   CCIDS = CCIDS || ' ' || ccdata(j); 
CCIDS = strip(CCIDS); 
do while msgdata(k) NE ' ' 
       put 'msgdata(i)'; 


I have given comments wherever it errored out. Please update me how to
solve these errors.

Alternatively, i tried even interacting SAS with REXX execs, but i was
getting some problems while executing. Can you tell me what changes
needs to be done inorder to make it work. This message is somewhat
longer as i need to post the entire program with input dataset and i'm
extremely sorry for that!.

Thanks in anticipation.

4.Send a mail with SAS

Hello everybody,

Is someone know how to send a mail with a programm SAS. The mail may
contain some sentence in bold, in color and underligned.



5.Sending mail with SAS

Hello SasUsers,

How to send a mail via SAS with the result ODS HTML directly in the
body of the mail.

Thanks. Ash007.

INPUT X1 X2 X3 X4 X5 $; CARDS;
2 5 5 1161 ABIEN
35 6 3 1336 ALMIC
82 1 5 1499 ANIEL

filename mm email
	to 				= " XXXX@XXXXX.COM "
	from 			= " XXXX@XXXXX.COM "
	subject 		= "test email formate"
	type 			= "text/html"
	content_type 	= "text/html";

ods html body = mm style = styles.default rs = none ;

proc print data = TABLE_BIDON; run;

ods html close;

6. Sending an E-Mail using SAS

7. Sending emails via Outlook from SAS but a security Yes/No box appe

8. Sending email from SAS using Gmail account

Return to sas


Who is online

Users browsing this forum: No registered users and 69 guest