BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
UMR13
Calcite | Level 5

Hello, 

 

I am relatively new to SAS 

 

I have three data columns with completion dates over 3 days. Some days do not have a date and some do which would indicate completion. How do i check which cells have dates completed across the board for all three days.  

 

Thank you. 

1 ACCEPTED SOLUTION

Accepted Solutions
ebowen
Quartz | Level 8

If you're looking to find the observations in your data that have missing values, you could use the cmiss function to count the number of missing values in the date variables and then output those observations where there are more than one. It would look something like this:

 

data out;
set in;
if cmiss(date1,date2,date3) > 0 then output;
run;

View solution in original post

3 REPLIES 3
ebowen
Quartz | Level 8

If you're looking to find the observations in your data that have missing values, you could use the cmiss function to count the number of missing values in the date variables and then output those observations where there are more than one. It would look something like this:

 

data out;
set in;
if cmiss(date1,date2,date3) > 0 then output;
run;
ebowen
Quartz | Level 8
Or you could look for observations with no missing values by asking for:
if cmiss(d1,d2,d3) = 0 then output;
UMR13
Calcite | Level 5

Thank you very much for your speedy reply. This helped Tremendously. 

SAS Innovate 2025: Call for Content

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!

Submit your idea!

Mastering the WHERE Clause in PROC SQL

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.

Discussion stats
  • 3 replies
  • 665 views
  • 0 likes
  • 2 in conversation