<?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: Compare intnx and prompt in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280441#M56668</link>
    <description>&lt;P&gt;Did you try the method with PM? What does your filter look like now?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;%put &amp;amp;8pm;&lt;/P&gt;</description>
    <pubDate>Mon, 27 Jun 2016 15:00:51 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2016-06-27T15:00:51Z</dc:date>
    <item>
      <title>Compare intnx and prompt</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280016#M56523</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am stuck on an issue when I try to write a filter. The program doesn't log me errors, but &amp;nbsp;the filter is not taken into account.&lt;/P&gt;&lt;P&gt;I have 3 data:&lt;/P&gt;&lt;P&gt;# one date prompt named "pm"&lt;/P&gt;&lt;P&gt;# one date named "initial_date"&lt;/P&gt;&lt;P&gt;# one number named "duration"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to select only rows where the end of the month of initial_date+duration (months) &amp;gt;= pm&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The filter I wrote&amp;nbsp;is this one:&lt;/P&gt;&lt;PRE&gt;WHERE %_eg_WhereParam( INTNX('month', 
INITIAL_DATE, + DURATION , 'e'), PM, GE, TYPE=D, IS_EXPLICIT=0 );&lt;/PRE&gt;&lt;P&gt;Can you tell me where the mistake is?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you by advance&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jun 2016 16:22:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280016#M56523</guid>
      <dc:creator>fabdu92</dc:creator>
      <dc:date>2016-06-24T16:22:49Z</dc:date>
    </item>
    <item>
      <title>Re: Compare intnx and prompt</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280084#M56541</link>
      <description>&lt;P&gt;Your prompts are macro variables, you need to reference them with a &amp;amp; in front.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;WHERE %_eg_WhereParam( INTNX('month', 
&amp;amp;INITIAL_DATE, &amp;amp;DURATION , 'e'), PM, GE, TYPE=D, IS_EXPLICIT=0 );&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I can't guarantee that will work since I don't know what the parameters look like or your data. They do have to line up and the code generated needs to be valid SAS code.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You don't need the + sign in front of duration.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Usually in macros you don't have the parameters in quotes (month and e) but I'm not familiar with the EG filter macro being used.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hopefully this helps get you started.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jun 2016 20:49:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280084#M56541</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-06-24T20:49:39Z</dc:date>
    </item>
    <item>
      <title>Re: Compare intnx and prompt</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280356#M56641</link>
      <description>&lt;P&gt;Thank you for your answer but yo misunderstood:&amp;nbsp;&lt;/P&gt;&lt;P&gt;My prompt is PM, Initial_date and duration are data gotten from&amp;nbsp;a previous task.&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jun 2016 08:56:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280356#M56641</guid>
      <dc:creator>fabdu92</dc:creator>
      <dc:date>2016-06-27T08:56:34Z</dc:date>
    </item>
    <item>
      <title>Re: Compare intnx and prompt</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280441#M56668</link>
      <description>&lt;P&gt;Did you try the method with PM? What does your filter look like now?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;%put &amp;amp;8pm;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jun 2016 15:00:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280441#M56668</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-06-27T15:00:51Z</dc:date>
    </item>
    <item>
      <title>Re: Compare intnx and prompt</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280714#M56771</link>
      <description>&lt;P&gt;Hey Reeza,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I've tried differently but always the same problem...&lt;/P&gt;&lt;P&gt;When I put PM, I have the result expected, that means "31MAY2016"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now I have calculated on the previous task a new data:&lt;/P&gt;&lt;P&gt;*DT_END&lt;/P&gt;&lt;P&gt;which is equals to&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;INTNX('month', 
INITIAL_DATE, + DURATION , 'e')&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is working.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So on my filter I do:&lt;/P&gt;&lt;PRE&gt;WHERE %_eg_WhereParam( DT_END, PM, GE, TYPE=D, IS_EXPLICIT=0 );&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;And still with this, it's like I have not written this filter...It output all rows not only those where DT_END &amp;gt;= PM&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2016 10:13:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Compare-intnx-and-prompt/m-p/280714#M56771</guid>
      <dc:creator>fabdu92</dc:creator>
      <dc:date>2016-06-28T10:13:07Z</dc:date>
    </item>
  </channel>
</rss>

