Write a SAS macro to calculate number of numbers in an
email address
Answers were Sorted based on User's Feedback
Answer / dey
%macro logic(email=);
data _null_;
length EMAIL $50;
Email=&email;
retain count 0;
do i = 1 to length(EMAIL);
if missing(substr(EMAIL,i,1)*1)=0 then
COUNT= COUNT +1;
end;
call symput('count',count);
RUN;
%put &count;
%mend logic;
%logic(email='dey_anurup123444@yahoo.12co.in')
Is This Answer Correct ? | 1 Yes | 1 No |
Answer / naresh
Use compress function and remove characters and special characters then you will get digits.. Now find the length of the string...
Is This Answer Correct ? | 0 Yes | 0 No |
what is scheduling and how will u implement it. In scheduling 5 jobs r running if there is an error occured at 3rd job and how will u check and waht necessary steps will u take not to repeat the same mistake
What do you know about symput and symget?
Define run-group processing?
how to delete the duplicate columns permanently in SQL
Explain the use of proc gplot? : sas-grid-administration
In PROC PRINT, can you print only variables that begin with the letter “A”?
what is the difference between floor and ceil functions in sas? : Sas-administrator
What is Transaction...? And what are Comment, Roll back n Save point..?
What is the difference between an informat and a format. Name three informats or formats.
what is the purpose of _error_? : Sas programming
what are the methods that you would employ to fine tune your SQL extract process using SAS/Access or Proc SQL?
What is the SAS data set?