<?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 AND TIME in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322956#M71522</link>
    <description>No problem, nice work!</description>
    <pubDate>Fri, 06 Jan 2017 12:45:59 GMT</pubDate>
    <dc:creator>TheShark</dc:creator>
    <dc:date>2017-01-06T12:45:59Z</dc:date>
    <item>
      <title>DATE AND TIME</title>
      <link>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322775#M71454</link>
      <description>&lt;P&gt;I have an urgent situation. I am trying to export excel file into current date and current time.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Will be generating two files each day and final output needs to be like below.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;File should be named as such [mmddyyyyhhmmss]_ABC&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Please help urgently. Thank you.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Jan 2017 20:02:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322775#M71454</guid>
      <dc:creator>Di_Pat</dc:creator>
      <dc:date>2017-01-05T20:02:56Z</dc:date>
    </item>
    <item>
      <title>Re: DATE AND TIME</title>
      <link>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322781#M71456</link>
      <description>&lt;P&gt;Create a timestamp!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc format;
  picture myfmt low-high = '%Y%0m%0d_%0H%0M%0S' (datatype = datetime) ;
run ;

%let timestamp=%sysfunc(datetime(), myfmt.);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 05 Jan 2017 20:23:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322781#M71456</guid>
      <dc:creator>TheShark</dc:creator>
      <dc:date>2017-01-05T20:23:34Z</dc:date>
    </item>
    <item>
      <title>Re: DATE AND TIME</title>
      <link>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322797#M71463</link>
      <description>&lt;P&gt;marco variable is created but proc export part is not working&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;data _null_ ;&lt;BR /&gt;format dt mmddyy10. tm time. ;&lt;BR /&gt;dt = today() ;&lt;BR /&gt;tm = timepart(datetime()) ;&lt;BR /&gt;charval = compress(put(dt,mmddyy10.)||put(tm,time.), ":/") ;&lt;BR /&gt;call symput("dateval",charval) ;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;%put &amp;amp;dateval ;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc export data=&amp;nbsp;abc&amp;nbsp;&lt;BR /&gt;outfile='C:\Users\mno\New folder\&amp;amp;dateval..xlsx'&lt;BR /&gt;dbms = xlsx replace ; putnames=no;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;final output is generated with name as "&lt;SPAN&gt;&amp;amp;&lt;/SPAN&gt;&lt;SPAN&gt;dateval.xlsx"&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;no error in log.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Jan 2017 20:55:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322797#M71463</guid>
      <dc:creator>Di_Pat</dc:creator>
      <dc:date>2017-01-05T20:55:24Z</dc:date>
    </item>
    <item>
      <title>Re: DATE AND TIME</title>
      <link>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322809#M71472</link>
      <description>&lt;P&gt;Thank you. This works in proc export. There was a typo in my datastep. Thank you.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Jan 2017 21:18:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322809#M71472</guid>
      <dc:creator>Di_Pat</dc:creator>
      <dc:date>2017-01-05T21:18:27Z</dc:date>
    </item>
    <item>
      <title>Re: DATE AND TIME</title>
      <link>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322956#M71522</link>
      <description>No problem, nice work!</description>
      <pubDate>Fri, 06 Jan 2017 12:45:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/DATE-AND-TIME/m-p/322956#M71522</guid>
      <dc:creator>TheShark</dc:creator>
      <dc:date>2017-01-06T12:45:59Z</dc:date>
    </item>
  </channel>
</rss>

