Please let us know if it worked for you
data emails;
input emails:$200.;
id=_n_; /*This is one way of Iding, there are several other ways*/
cards;
sai@gmail.com
kiran@gmail.com
;
run;
%macro mac(no=);
data _null_;
set emails;
where id=&no;
call symput('email',emails);
stop;
run;
%put &=email;
/****Add Email Sending Code Here****/
%mend mac;
%mac(no=1);
%mac(no=2);
You can build a custom format that maps the index values to email adresses. Build that format from a dataset that contains both.
Read the documentation!
@saikiran_nemani wrote:
Can you explain
To show you where such a format would be implemented, you need to show us your macro code.
Please let us know if it worked for you
data emails;
input emails:$200.;
id=_n_; /*This is one way of Iding, there are several other ways*/
cards;
sai@gmail.com
kiran@gmail.com
;
run;
%macro mac(no=);
data _null_;
set emails;
where id=&no;
call symput('email',emails);
stop;
run;
%put &=email;
/****Add Email Sending Code Here****/
%mend mac;
%mac(no=1);
%mac(no=2);
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.
Find more tutorials on the SAS Users YouTube channel.