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);
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—just $495!
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.