IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Read sas dataset and send email if missing values are found


IBM Mainframe Forums -> All Other Mainframe Topics
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
srinivaspsai

New User


Joined: 22 Jul 2010
Posts: 1
Location: pune

PostPosted: Fri Aug 27, 2010 11:51 am
Reply with quote

Hi,

I have a requirement where i need to read a sas dataset having 4 variables and if any missing values are present in any of the fields then an email will be genrated stating the same.

Is there any function or logic how to do the same?
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2481
Location: Netherlands, Amstelveen

PostPosted: Fri Aug 27, 2010 12:11 pm
Reply with quote

support.sas.com/documentation/cdl/en/hosto390/61886/HTML/default/viewer.htm#/documentation/cdl/en/hosto390/61886/HTML/default/a001412669.htm
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Fri Aug 27, 2010 4:55 pm
Reply with quote

Are the 4 variables all numeric? If so, this untested code should get you started:
Code:
DATA _NULL_;
     SET DDNAME.SASDB END=EOF;
     RETAIN MISSFLAG 0 ;
     IF VAR1 = . OR VAR2 = . OR VAR3 = . OR VAR4 = . THEN MISSFLAG = 1;
     IF EOF AND MISSFLAG = 1 THEN DO;
          <<send the email logic>>
                                  END;
As always with SAS, though, there are other ways to do it.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> All Other Mainframe Topics

 


Similar Topics
Topic Forum Replies
No new posts Error to read log with rexx CLIST & REXX 11
No new posts INCLUDE OMIT COND for Multiple values... DFSORT/ICETOOL 5
No new posts How I Found a Bug in a FORTRAN Compiler All Other Mainframe Topics 4
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
No new posts Replace Multiple Field values to Othe... DFSORT/ICETOOL 12
Search our Forums:

Back to Top