<?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: proc sql generate timestamp in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/proc-sql-generate-timestamp/m-p/267807#M269344</link>
    <description>Why store it as char? Use format=datetime 18&lt;BR /&gt;&lt;BR /&gt;Also, using automatic macro variable may be more efficient than using functions: &lt;BR /&gt;"&amp;amp;sysdate:&amp;amp;systime"dt&lt;BR /&gt;One drawback with thus this will only give you the minute.</description>
    <pubDate>Tue, 03 May 2016 05:04:57 GMT</pubDate>
    <dc:creator>LinusH</dc:creator>
    <dc:date>2016-05-03T05:04:57Z</dc:date>
    <item>
      <title>proc sql generate timestamp</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-sql-generate-timestamp/m-p/267578#M269342</link>
      <description>&lt;P&gt;Hi SAS Experts,&lt;/P&gt;
&lt;P&gt;I need to create an XML file that has a unique ID every time I generte it.&lt;/P&gt;
&lt;P&gt;The data fo create the XML is extracted from a sas data set using proc sql and now I wonder&lt;/P&gt;
&lt;P&gt;how to generate a unique timestamp, preferable something just numbers.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sql;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;create table VDR as &lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;select &lt;BR /&gt;%sysfunc(datetime(),datetime18.)&lt;BR /&gt;from sashelp.class;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any ideas?&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2016 12:40:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-sql-generate-timestamp/m-p/267578#M269342</guid>
      <dc:creator>metallon</dc:creator>
      <dc:date>2016-05-02T12:40:25Z</dc:date>
    </item>
    <item>
      <title>Re: proc sql generate timestamp</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-sql-generate-timestamp/m-p/267590#M269343</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sql;&lt;BR /&gt;select *, put(datetime(),datetime18.) as timestamp from sashelp.class;&lt;BR /&gt;quit;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Manohar&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2016 13:16:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-sql-generate-timestamp/m-p/267590#M269343</guid>
      <dc:creator>Manu_SAS</dc:creator>
      <dc:date>2016-05-02T13:16:41Z</dc:date>
    </item>
    <item>
      <title>Re: proc sql generate timestamp</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-sql-generate-timestamp/m-p/267807#M269344</link>
      <description>Why store it as char? Use format=datetime 18&lt;BR /&gt;&lt;BR /&gt;Also, using automatic macro variable may be more efficient than using functions: &lt;BR /&gt;"&amp;amp;sysdate:&amp;amp;systime"dt&lt;BR /&gt;One drawback with thus this will only give you the minute.</description>
      <pubDate>Tue, 03 May 2016 05:04:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-sql-generate-timestamp/m-p/267807#M269344</guid>
      <dc:creator>LinusH</dc:creator>
      <dc:date>2016-05-03T05:04:57Z</dc:date>
    </item>
  </channel>
</rss>

