<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic SAS Tip: Use IS MISSING and IS NULL with Numeric or Character Variables in SAS Tips from the Community</title>
    <link>https://communities.sas.com/t5/SAS-Tips-from-the-Community/SAS-Tip-Use-IS-MISSING-and-IS-NULL-with-Numeric-or-Character/m-p/475183#M170</link>
    <description>&lt;P&gt;&lt;SPAN&gt;The IS MISSING and IS NULL operators, which are used with a WHERE&amp;nbsp;&lt;/SPAN&gt;statement&lt;SPAN&gt;, can handle character or numeric variables. They also work with the NOT operator:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*** create a sample dataset with some missing values;
data makemissing;
    set sashelp.class;
    if substr(name,1,1) eq 'J' then initial='J';
    if 11 le age le 13 then newage=age;
run;
 
*** use missing;
proc print data=makemissing;
    where initial is missing and newage is not missing;
run;
 
*** or equivalently, use IS NULL;
proc print data=makemissing;
    where initial is null and newage is not null;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;SPAN&gt;This may be especially useful in a macro that takes mixed-type variables as parameters in a where clause.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;Thanks to &lt;SPAN&gt;Mary Rosenbloom&lt;/SPAN&gt; for submitting this tip on sasCommunity.org!&lt;/EM&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 03 Jul 2018 14:17:29 GMT</pubDate>
    <dc:creator>SAS_Tipster</dc:creator>
    <dc:date>2018-07-03T14:17:29Z</dc:date>
    <item>
      <title>SAS Tip: Use IS MISSING and IS NULL with Numeric or Character Variables</title>
      <link>https://communities.sas.com/t5/SAS-Tips-from-the-Community/SAS-Tip-Use-IS-MISSING-and-IS-NULL-with-Numeric-or-Character/m-p/475183#M170</link>
      <description>&lt;P&gt;&lt;SPAN&gt;The IS MISSING and IS NULL operators, which are used with a WHERE&amp;nbsp;&lt;/SPAN&gt;statement&lt;SPAN&gt;, can handle character or numeric variables. They also work with the NOT operator:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*** create a sample dataset with some missing values;
data makemissing;
    set sashelp.class;
    if substr(name,1,1) eq 'J' then initial='J';
    if 11 le age le 13 then newage=age;
run;
 
*** use missing;
proc print data=makemissing;
    where initial is missing and newage is not missing;
run;
 
*** or equivalently, use IS NULL;
proc print data=makemissing;
    where initial is null and newage is not null;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;SPAN&gt;This may be especially useful in a macro that takes mixed-type variables as parameters in a where clause.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;Thanks to &lt;SPAN&gt;Mary Rosenbloom&lt;/SPAN&gt; for submitting this tip on sasCommunity.org!&lt;/EM&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Jul 2018 14:17:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Tips-from-the-Community/SAS-Tip-Use-IS-MISSING-and-IS-NULL-with-Numeric-or-Character/m-p/475183#M170</guid>
      <dc:creator>SAS_Tipster</dc:creator>
      <dc:date>2018-07-03T14:17:29Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Tip: Use IS MISSING and IS NULL with Numeric or Character Variables</title>
      <link>https://communities.sas.com/t5/SAS-Tips-from-the-Community/SAS-Tip-Use-IS-MISSING-and-IS-NULL-with-Numeric-or-Character/m-p/475191#M171</link>
      <description>&lt;P&gt;There is also the missing() function which does either data type.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Jul 2018 14:26:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Tips-from-the-Community/SAS-Tip-Use-IS-MISSING-and-IS-NULL-with-Numeric-or-Character/m-p/475191#M171</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-07-03T14:26:52Z</dc:date>
    </item>
  </channel>
</rss>

