<?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: Current Date Proc SQL in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Current-Date-Proc-SQL/m-p/274665#M269579</link>
    <description>&lt;P&gt;I knew I could use today in a datastep but was unaware I could use it in proc sql.&amp;nbsp; Thanks for the advice.&lt;/P&gt;</description>
    <pubDate>Thu, 02 Jun 2016 13:47:09 GMT</pubDate>
    <dc:creator>DavidPhillips2</dc:creator>
    <dc:date>2016-06-02T13:47:09Z</dc:date>
    <item>
      <title>Current Date Proc SQL</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Current-Date-Proc-SQL/m-p/274660#M269577</link>
      <description>&lt;P&gt;When I create tables in oracle I use sysdate() to set add a time stamp column, however this errors in proc SQL.&amp;nbsp; How can I add the current date in proc sql?&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jun 2016 13:29:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Current-Date-Proc-SQL/m-p/274660#M269577</guid>
      <dc:creator>DavidPhillips2</dc:creator>
      <dc:date>2016-06-02T13:29:49Z</dc:date>
    </item>
    <item>
      <title>Re: Current Date Proc SQL</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Current-Date-Proc-SQL/m-p/274663#M269578</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/5059"&gt;@DavidPhillips2﻿&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In general you can use the SAS datastep functions (there are exceptions!). For the current date you have today(). If you want the date and time in one use datetime().&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
   select name, datetime() format=datetime22. 
   from sashelp.class;
quit;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 02 Jun 2016 13:45:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Current-Date-Proc-SQL/m-p/274663#M269578</guid>
      <dc:creator>jklaverstijn</dc:creator>
      <dc:date>2016-06-02T13:45:54Z</dc:date>
    </item>
    <item>
      <title>Re: Current Date Proc SQL</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Current-Date-Proc-SQL/m-p/274665#M269579</link>
      <description>&lt;P&gt;I knew I could use today in a datastep but was unaware I could use it in proc sql.&amp;nbsp; Thanks for the advice.&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jun 2016 13:47:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Current-Date-Proc-SQL/m-p/274665#M269579</guid>
      <dc:creator>DavidPhillips2</dc:creator>
      <dc:date>2016-06-02T13:47:09Z</dc:date>
    </item>
  </channel>
</rss>

