<?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: Date Macro Financial Year in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430479#M106405</link>
    <description>&lt;P&gt;What exactly do you want to do?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;See this thread for inspiration&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://communities.sas.com/t5/SAS-Visual-Analytics/I-would-like-to-know-how-to-make-fiscal-year/td-p/145598" target="_blank"&gt;https://communities.sas.com/t5/SAS-Visual-Analytics/I-would-like-to-know-how-to-make-fiscal-year/td-p/145598&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 24 Jan 2018 15:13:15 GMT</pubDate>
    <dc:creator>PeterClemmensen</dc:creator>
    <dc:date>2018-01-24T15:13:15Z</dc:date>
    <item>
      <title>Date Macro Financial Year</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430475#M106403</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Any idea how to create a date macro for the financial year please?&lt;BR /&gt;&lt;BR /&gt;Currently we key in the dates as below&lt;BR /&gt;&lt;BR /&gt;%let fin_start = 01APR2017;&lt;BR /&gt;%let fin_end = 01APR2018;&lt;BR /&gt;&lt;BR /&gt;Thanks</description>
      <pubDate>Wed, 24 Jan 2018 15:10:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430475#M106403</guid>
      <dc:creator>Brandon16</dc:creator>
      <dc:date>2018-01-24T15:10:33Z</dc:date>
    </item>
    <item>
      <title>Re: Date Macro Financial Year</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430479#M106405</link>
      <description>&lt;P&gt;What exactly do you want to do?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;See this thread for inspiration&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://communities.sas.com/t5/SAS-Visual-Analytics/I-would-like-to-know-how-to-make-fiscal-year/td-p/145598" target="_blank"&gt;https://communities.sas.com/t5/SAS-Visual-Analytics/I-would-like-to-know-how-to-make-fiscal-year/td-p/145598&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jan 2018 15:13:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430479#M106405</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2018-01-24T15:13:15Z</dc:date>
    </item>
    <item>
      <title>Re: Date Macro Financial Year</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430481#M106406</link>
      <description>I want to take out the manual element of it so we are never required to update it, even when the financial year changes.</description>
      <pubDate>Wed, 24 Jan 2018 15:15:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430481#M106406</guid>
      <dc:creator>Brandon16</dc:creator>
      <dc:date>2018-01-24T15:15:29Z</dc:date>
    </item>
    <item>
      <title>Re: Date Macro Financial Year</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430491#M106407</link>
      <description>&lt;P&gt;Something like this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data _null_;
   call symputx('fin_start', mdy(4, 1, year(today())));
   call symputx('fin_end', mdy(4, 1, year(today())+1));
run;

%put &amp;amp;fin_start. &amp;amp;fin_end.;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 24 Jan 2018 15:27:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430491#M106407</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2018-01-24T15:27:35Z</dc:date>
    </item>
    <item>
      <title>Re: Date Macro Financial Year</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430495#M106409</link>
      <description>&lt;P&gt;How do you use that information? If the main purpose is to determine if a date value is in a given fiscal year you might get by with either a custom function or something similar to:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;%macro myfiscalyear(date);
/* date must be a sas date value either 
  in the 'ddmmyyyy'd form or SAS numeric value of a date*/
%eval (%sysfunc(year(&amp;amp;date)) + %eval(%sysfunc(month(&amp;amp;date))&amp;gt; 4 ))
%mend;

%put Fiscal year of 23AUG2018 is %myfiscalyear('23AUG2018'd);


%put Fiscal year of 12345 is %myfiscalyear(12345);
&lt;/PRE&gt;</description>
      <pubDate>Wed, 24 Jan 2018 15:40:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430495#M106409</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-01-24T15:40:03Z</dc:date>
    </item>
    <item>
      <title>Re: Date Macro Financial Year</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430916#M106534</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%let fin_start = %sysfunc(intnx(year.4,%sysfunc(today()),0,b),date9.);
%let fin_end =  %sysfunc(intnx(year,"&amp;amp;fin_start"d,1,s),date9.);

%put &amp;amp;fin_start  &amp;amp;fin_end ;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 25 Jan 2018 14:09:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Date-Macro-Financial-Year/m-p/430916#M106534</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2018-01-25T14:09:25Z</dc:date>
    </item>
  </channel>
</rss>

