<?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 How to limit the calculation to three business days excluding weekends in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164373#M12650</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;BR /&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am needing to calculate three business days from OE_DATE &amp;amp; DLVR_STRT_DATE and using the below i am getting three business days between order date &amp;amp; delivery date. however if an order is placed on tuesday then i am getting three business days as wed, thu, fri, sat &amp;amp; sun. I need the sat &amp;amp; sun excluded from the calc as it is &amp;gt; 3 business days. The issue is with orders having order date on tuesdays where the made orders have delivery date on wed, thu, fri, sat &amp;amp; sun where delivery date on sat, sun should be miss as it is &amp;gt; 3 business days. Please advise.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF intck('WEEKDAY',OE_DATE,DLVR_STRT_DATE) LE 3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; then c = 'made'&lt;/P&gt;&lt;P&gt;else&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; c = 'miss';&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 02 Apr 2014 12:23:29 GMT</pubDate>
    <dc:creator>sharath_rk</dc:creator>
    <dc:date>2014-04-02T12:23:29Z</dc:date>
    <item>
      <title>How to limit the calculation to three business days excluding weekends</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164373#M12650</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;BR /&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am needing to calculate three business days from OE_DATE &amp;amp; DLVR_STRT_DATE and using the below i am getting three business days between order date &amp;amp; delivery date. however if an order is placed on tuesday then i am getting three business days as wed, thu, fri, sat &amp;amp; sun. I need the sat &amp;amp; sun excluded from the calc as it is &amp;gt; 3 business days. The issue is with orders having order date on tuesdays where the made orders have delivery date on wed, thu, fri, sat &amp;amp; sun where delivery date on sat, sun should be miss as it is &amp;gt; 3 business days. Please advise.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF intck('WEEKDAY',OE_DATE,DLVR_STRT_DATE) LE 3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; then c = 'made'&lt;/P&gt;&lt;P&gt;else&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; c = 'miss';&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 12:23:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164373#M12650</guid>
      <dc:creator>sharath_rk</dc:creator>
      <dc:date>2014-04-02T12:23:29Z</dc:date>
    </item>
    <item>
      <title>Re: How to limit the calculation to three business days excluding weekends</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164374#M12651</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;As you are only looking at a few possibilities, maybe best to just do it with manual if statements, e.g.&lt;/P&gt;&lt;P&gt;If weekday(dlvr_strt_date)=1 then checkdt=dlvr_strt_date + 4; /* Sunday so Mon/Tues/Wed */&lt;/P&gt;&lt;P&gt;If weekday(dlvr_strt_date)=2 then checkdt=dlvr_strt_date + 3; /* Monday so Tues/Wed/Thurs */&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;If weekday(dvlr_strt_date)=6 then checkdt=dlvr_strt_date + 5;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Friday so wed */&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If dlvr_strt_date &amp;lt;= oe_date &amp;lt;= checkdt then "made";&lt;/P&gt;&lt;P&gt;else "miss";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note-can't check this at the moment.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 13:18:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164374#M12651</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2014-04-02T13:18:53Z</dc:date>
    </item>
    <item>
      <title>Re: How to limit the calculation to three business days excluding weekends</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164375#M12652</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE __jive_macro_name="quote" class="jive_text_macro jive_macro_quote" modifiedtitle="true"&gt;
&lt;P&gt;I am needing to calculate three business days from OE_DATE &amp;amp; DLVR_STRT_DATE&lt;/P&gt;
&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do you need to calculate the business day that is 3 days away from each of the date above?&lt;/P&gt;&lt;P&gt;Or if the duration between the two dates is greater than 3 days?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try using intnx to calculate the 3 day delivery date and check if delivery date is after that date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;expected_delivery=intnx('weekday', OE_DATE, 3);&lt;/P&gt;&lt;P&gt;if DLVR_STRT_DATE&amp;gt;expected_delivery then c='made';&lt;/P&gt;&lt;P&gt;else c='miss';&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 14:27:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164375#M12652</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2014-04-02T14:27:16Z</dc:date>
    </item>
    <item>
      <title>Re: How to limit the calculation to three business days excluding weekends</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164376#M12653</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;made = OE_DATE + 3 business days should be less than equal to DLVR_STRT_DATE minus weekends. Please advise.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for example : OE_DATE = Tuesday + 3 business days ( wed, thu, fri ) less than equal to DLVR_STRT_DATE then c='made';&lt;/P&gt;&lt;P&gt;else c='miss';&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the below logic works for all days except tuesday where made orders are from wed, thu, fri, sat &amp;amp; sun.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF intck('WEEKDAY',OE_DATE,DLVR_STRT_DATE) LE 3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; then c = 'made'&lt;/P&gt;&lt;P&gt;else&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; c = 'miss';&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 14:52:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164376#M12653</guid>
      <dc:creator>sharath_rk</dc:creator>
      <dc:date>2014-04-02T14:52:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to limit the calculation to three business days excluding weekends</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164377#M12654</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Did you try the code included?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;expected_delivery=intnx('weekday', OE_DATE, 3);&lt;/P&gt;&lt;P&gt;if DLVR_STRT_DATE&amp;gt;expected_delivery then c='made';&lt;/P&gt;&lt;P&gt;else c='miss';&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 14:56:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164377#M12654</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2014-04-02T14:56:23Z</dc:date>
    </item>
    <item>
      <title>Re: How to limit the calculation to three business days excluding weekends</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164378#M12655</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The duration between two date columns should be LE 3 business days.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 14:58:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164378#M12655</guid>
      <dc:creator>sharath_rk</dc:creator>
      <dc:date>2014-04-02T14:58:45Z</dc:date>
    </item>
    <item>
      <title>Re: How to limit the calculation to three business days excluding weekends</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164379#M12656</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It worked &lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://communities.sas.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt; Thank you very much. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 15:15:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/How-to-limit-the-calculation-to-three-business-days-excluding/m-p/164379#M12656</guid>
      <dc:creator>sharath_rk</dc:creator>
      <dc:date>2014-04-02T15:15:49Z</dc:date>
    </item>
  </channel>
</rss>

