<?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 Re: Use formatted value in where statement in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Use-formatted-value-in-where-statement/m-p/394686#M95134</link>
    <description>&lt;P&gt;Use this:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;where put(engines,enginesSML.) = 'Large';&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Mon, 11 Sep 2017 14:03:22 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2017-09-11T14:03:22Z</dc:date>
    <item>
      <title>Use formatted value in where statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Use-formatted-value-in-where-statement/m-p/394683#M95132</link>
      <description>&lt;P&gt;I would like to use formats to group values and then select one of the formed groups with a where statement.&lt;/P&gt;&lt;P&gt;Consider the following simple code:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc format;
      value enginesSML
            low-2 = 'Small'
            2-3 = 'Medium'
            3-high = 'Large';
run;

data tmp;
      format engines enginesSML.;
      set sashelp.cars(keep=engineSize);
      engines = engineSize;
run;


proc print data=tmp(obs=5);
      *where engines='Large'; /*Does not work*/
       where engines &amp;gt; 3; /*works*/
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;How can I get this statement to work?&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;where engines='Large';&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm on SAS 9.2.&lt;/P&gt;</description>
      <pubDate>Mon, 11 Sep 2017 14:00:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Use-formatted-value-in-where-statement/m-p/394683#M95132</guid>
      <dc:creator>JHenkel</dc:creator>
      <dc:date>2017-09-11T14:00:09Z</dc:date>
    </item>
    <item>
      <title>Re: Use formatted value in where statement</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Use-formatted-value-in-where-statement/m-p/394686#M95134</link>
      <description>&lt;P&gt;Use this:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;where put(engines,enginesSML.) = 'Large';&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 11 Sep 2017 14:03:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Use-formatted-value-in-where-statement/m-p/394686#M95134</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2017-09-11T14:03:22Z</dc:date>
    </item>
  </channel>
</rss>

