<?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: how do the macro define yesterday in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/how-do-the-macro-define-yesterday/m-p/14359#M1819</link>
    <description>done.&lt;BR /&gt;
thank you very much.</description>
    <pubDate>Thu, 02 Apr 2009 09:41:17 GMT</pubDate>
    <dc:creator>deleted_user</dc:creator>
    <dc:date>2009-04-02T09:41:17Z</dc:date>
    <item>
      <title>how do the macro define yesterday</title>
      <link>https://communities.sas.com/t5/SAS-Programming/how-do-the-macro-define-yesterday/m-p/14357#M1817</link>
      <description>hi,&lt;BR /&gt;
i am trying to tail timestamp to the datasets' name, but when finishing the macro, i found it was difficult to define yesterday like 20090401.&lt;BR /&gt;
Thank you in advance for your really appreciated help.</description>
      <pubDate>Thu, 02 Apr 2009 03:18:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/how-do-the-macro-define-yesterday/m-p/14357#M1817</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2009-04-02T03:18:16Z</dc:date>
    </item>
    <item>
      <title>Re: how do the macro define yesterday</title>
      <link>https://communities.sas.com/t5/SAS-Programming/how-do-the-macro-define-yesterday/m-p/14358#M1818</link>
      <description>Not sure about what your trying to do, but I'll try to help...&lt;BR /&gt;
&lt;BR /&gt;
Yesterday could be defined as TODAY()-1, or any other date value (var) minus 1 (day)&lt;BR /&gt;
&lt;BR /&gt;
To fix the dataset name, you could do something like that.&lt;BR /&gt;
&lt;BR /&gt;
* create macro var YESTERDAY with yesterday date yymmddn8. formated */&lt;BR /&gt;
data _null_;&lt;BR /&gt;
&lt;BR /&gt;
/* cats functions is just used for text trimming */&lt;BR /&gt;
call symput('YESTERDAY',cats(put(TODAY()-1,yymmddn8.)));&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
* print macro var value, just for checking;&lt;BR /&gt;
%put &amp;amp;YESTERDAY; &lt;BR /&gt;
&lt;BR /&gt;
Then you will be abble to us &amp;amp;YESTERDAY with your dataset naming, say:&lt;BR /&gt;
&lt;BR /&gt;
data MYTABLE_&amp;amp;YESTERDAY;&lt;BR /&gt;
...&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
Hope it helps.&lt;BR /&gt;
&lt;BR /&gt;
Greetings from Portugal.&lt;BR /&gt;
&lt;BR /&gt;
Daniel Santos at &lt;A href="http://www.cgd.pt" target="_blank"&gt;www.cgd.pt&lt;/A&gt;</description>
      <pubDate>Thu, 02 Apr 2009 07:13:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/how-do-the-macro-define-yesterday/m-p/14358#M1818</guid>
      <dc:creator>DanielSantos</dc:creator>
      <dc:date>2009-04-02T07:13:17Z</dc:date>
    </item>
    <item>
      <title>Re: how do the macro define yesterday</title>
      <link>https://communities.sas.com/t5/SAS-Programming/how-do-the-macro-define-yesterday/m-p/14359#M1819</link>
      <description>done.&lt;BR /&gt;
thank you very much.</description>
      <pubDate>Thu, 02 Apr 2009 09:41:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/how-do-the-macro-define-yesterday/m-p/14359#M1819</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2009-04-02T09:41:17Z</dc:date>
    </item>
  </channel>
</rss>

