<?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 Dates, Times, and Interval Functions in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/SAS-Dates-Times-and-Interval-Functions/m-p/30218#M4101</link>
    <description>When trying to use the interval function (intnx) to calculate the dates for the Monday of the previous 4 weeks based upon todays date, I am being returned a spureous date for week3. &lt;BR /&gt;
&lt;BR /&gt;
Select Data:&lt;BR /&gt;
&lt;BR /&gt;
Today = today()&lt;BR /&gt;
Week1 = INTNX('week1.2',today(),0)&lt;BR /&gt;
Week2 = INTNX('week2.2',today(),0)&lt;BR /&gt;
Week3 = INTNX('week3.2',today(),0)&lt;BR /&gt;
Week4 = INTNX('week4.2',today(),0)&lt;BR /&gt;
&lt;BR /&gt;
Output:&lt;BR /&gt;
&lt;BR /&gt;
Today = 02/06/2010	&lt;BR /&gt;
Week1 = 31/05/2010	&lt;BR /&gt;
Week2 = 24/05/2010	&lt;BR /&gt;
Week3 = 31/05/2010	(should be 17/05/2010)&lt;BR /&gt;
Week4 = 10/05/2010&lt;BR /&gt;
&lt;BR /&gt;
Any ideas?&lt;BR /&gt;
&lt;BR /&gt;
Regards&lt;BR /&gt;
&lt;BR /&gt;
Len Harbottle</description>
    <pubDate>Wed, 02 Jun 2010 11:21:15 GMT</pubDate>
    <dc:creator>LenHarbottle</dc:creator>
    <dc:date>2010-06-02T11:21:15Z</dc:date>
    <item>
      <title>SAS Dates, Times, and Interval Functions</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/SAS-Dates-Times-and-Interval-Functions/m-p/30218#M4101</link>
      <description>When trying to use the interval function (intnx) to calculate the dates for the Monday of the previous 4 weeks based upon todays date, I am being returned a spureous date for week3. &lt;BR /&gt;
&lt;BR /&gt;
Select Data:&lt;BR /&gt;
&lt;BR /&gt;
Today = today()&lt;BR /&gt;
Week1 = INTNX('week1.2',today(),0)&lt;BR /&gt;
Week2 = INTNX('week2.2',today(),0)&lt;BR /&gt;
Week3 = INTNX('week3.2',today(),0)&lt;BR /&gt;
Week4 = INTNX('week4.2',today(),0)&lt;BR /&gt;
&lt;BR /&gt;
Output:&lt;BR /&gt;
&lt;BR /&gt;
Today = 02/06/2010	&lt;BR /&gt;
Week1 = 31/05/2010	&lt;BR /&gt;
Week2 = 24/05/2010	&lt;BR /&gt;
Week3 = 31/05/2010	(should be 17/05/2010)&lt;BR /&gt;
Week4 = 10/05/2010&lt;BR /&gt;
&lt;BR /&gt;
Any ideas?&lt;BR /&gt;
&lt;BR /&gt;
Regards&lt;BR /&gt;
&lt;BR /&gt;
Len Harbottle</description>
      <pubDate>Wed, 02 Jun 2010 11:21:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/SAS-Dates-Times-and-Interval-Functions/m-p/30218#M4101</guid>
      <dc:creator>LenHarbottle</dc:creator>
      <dc:date>2010-06-02T11:21:15Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Dates, Times, and Interval Functions</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/SAS-Dates-Times-and-Interval-Functions/m-p/30219#M4102</link>
      <description>Suggest you review the SAS INTNX DOC on how you want to use the INTNX function with the WEEK value and a "multiple" *AND* and a  "shift-index".  Possibly you want to be incrementing (actually it would be decrementing) argument #3 instead for a prior period start date?  Maybe it would be helpful to explain what you are trying to accomplish with the SAS expressions?&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.</description>
      <pubDate>Thu, 03 Jun 2010 02:05:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/SAS-Dates-Times-and-Interval-Functions/m-p/30219#M4102</guid>
      <dc:creator>sbb</dc:creator>
      <dc:date>2010-06-03T02:05:42Z</dc:date>
    </item>
  </channel>
</rss>

