<?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 date and time in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338715#M22500</link>
    <description>&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;(WHERE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; t1.gdt_login_date &amp;gt;=today()&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;-&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;30&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;) i have used this date function. but i'm getting time with date. i want only date with out time.&lt;/P&gt;</description>
    <pubDate>Tue, 07 Mar 2017 08:53:46 GMT</pubDate>
    <dc:creator>Ishwarkumar</dc:creator>
    <dc:date>2017-03-07T08:53:46Z</dc:date>
    <item>
      <title>date and time</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338715#M22500</link>
      <description>&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;(WHERE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; t1.gdt_login_date &amp;gt;=today()&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;-&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;30&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;) i have used this date function. but i'm getting time with date. i want only date with out time.&lt;/P&gt;</description>
      <pubDate>Tue, 07 Mar 2017 08:53:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338715#M22500</guid>
      <dc:creator>Ishwarkumar</dc:creator>
      <dc:date>2017-03-07T08:53:46Z</dc:date>
    </item>
    <item>
      <title>Results Viewer - SAS Output Frame is Blank</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338688#M22504</link>
      <description>&lt;P&gt;I'm having a data. when i'm running it. its showing blank in the result.&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;PROC&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;SQL&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;CREATE&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;TABLE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; WORK.FILTER_FOR_GBLT_USER_LOG_0005 &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AS&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;SELECT&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; t1.GNUM_USERID, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;t1.GNUM_SEAT_ID,&lt;/P&gt;&lt;P&gt;t1.GDT_LOGIN_DATE,&lt;/P&gt;&lt;P&gt;t1.GDT_LOGUTT_DATE,&lt;/P&gt;&lt;P&gt;t1.GSTR_IP_NUMBER,&lt;/P&gt;&lt;P&gt;t1.GNUM_HOSPITAL_CODE&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;FROM&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORARAJ.GBLT_USER_LOG t1&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;WHERE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; t1.GDT_LOGIN_DATE &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;between&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;'07Mar2017:00:00:00'dt&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;and&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;'06Feb2017:00:00:00'dt&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;QUIT&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;　&lt;/P&gt;&lt;P&gt;this is the code i have used... can u solve this thing...&lt;/P&gt;</description>
      <pubDate>Tue, 07 Mar 2017 07:25:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338688#M22504</guid>
      <dc:creator>Ishwarkumar</dc:creator>
      <dc:date>2017-03-07T07:25:01Z</dc:date>
    </item>
    <item>
      <title>Re: Results Viewer - SAS Output Frame is Blank</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338689#M22505</link>
      <description>&lt;P&gt;And it is not even showing errors.&lt;/P&gt;</description>
      <pubDate>Tue, 07 Mar 2017 07:27:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338689#M22505</guid>
      <dc:creator>Ishwarkumar</dc:creator>
      <dc:date>2017-03-07T07:27:13Z</dc:date>
    </item>
    <item>
      <title>Re: date and time</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338720#M22501</link>
      <description>&lt;P&gt;To extract the data from a datetime value, use the datepart() function.&lt;/P&gt;</description>
      <pubDate>Tue, 07 Mar 2017 09:00:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338720#M22501</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2017-03-07T09:00:23Z</dc:date>
    </item>
    <item>
      <title>Re: date and time</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338728#M22502</link>
      <description>&lt;P&gt;ya. but i'm not getting it.&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;PROC&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;SQL&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;CREATE&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;TABLE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; WORK.FILTER_FOR_GBLT_USER_LOG &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;AS&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;SELECT&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; t1.gnum_userid, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;t1.gnum_seat_id,&lt;/P&gt;&lt;P&gt;t1.gdt_login_date,&lt;/P&gt;&lt;P&gt;t1.gdt_logutt_date,&lt;/P&gt;&lt;P&gt;t1.gstr_ip_number,&lt;/P&gt;&lt;P&gt;t1.gnum_hospital_code,&lt;/P&gt;&lt;P&gt;t1.gnum_user_type_id&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;FROM&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ANDHRA.GBLT_USER_LOG t1&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;WHERE&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; t1.gdt_login_date &amp;gt;=today()-&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;30&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;QUIT&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;this is the program i have used.&lt;/P&gt;&lt;P&gt;can you show mw the syntax by using today function&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Mar 2017 09:18:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338728#M22502</guid>
      <dc:creator>Ishwarkumar</dc:creator>
      <dc:date>2017-03-07T09:18:09Z</dc:date>
    </item>
    <item>
      <title>Re: date and time</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338736#M22503</link>
      <description>&lt;P&gt;So what part do you not get? &amp;nbsp;Your code seems fine, though you would go a long way if you apply some good coding practices to it to make it readable (and use the {i} to post code):&lt;/P&gt;
&lt;PRE&gt;proc sql;
  create table WORK.FILTER_FOR_GBLT_USER_LOG as
  select  T1.GNUM_USERID,
          T1.GNUM_SEAT_ID,
          T1.GDT_LOGIN_DATE,
          T1.GDT_LOGUTT_DATE,
          T1.GSTR_IP_NUMBER,
          T1.GNUM_HOSPITAL_CODE,
          T1.GNUM_USER_TYPE_ID
  from    ANDHRA.GBLT_USER_LOG T1
  where   T1.GDT_LOGIN_DATE &amp;gt;= (today()-30);
quit;
&lt;/PRE&gt;
&lt;P&gt;The only thing I added was the brackets around the today() - 30 to make it clear we want 30 days off todays date. &amp;nbsp;Do be aware this assumes that T1.GDT_LOGIN_DATE is a date variable. &amp;nbsp;If its a datetime then:&lt;/P&gt;
&lt;PRE&gt;  where   datepart(T1.GDT_LOGIN_DATE) &amp;gt;= (today()-30);
&lt;/PRE&gt;</description>
      <pubDate>Tue, 07 Mar 2017 09:59:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338736#M22503</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2017-03-07T09:59:20Z</dc:date>
    </item>
    <item>
      <title>Re: date and time</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338771#M22506</link>
      <description>&lt;P&gt;From the code you sent me in a personal message:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;PROC SQL;
  CREATE TABLE WORK.FILTER_FOR_GBLT_USER_LOG AS
  SELECT t1.gnum_userid,
    t1.gnum_seat_id,
    DATEPART(t1.gdt_login_date) format=date9. as  gdt_login_date,
    DATEPART(t1.gdt_logutt_date) format=date9. as  gdt_logutt_date,
    t1.gstr_ip_number,
    t1.gnum_hospital_code,
    t1.gnum_user_type_id
  FROM ANDHRA.GBLT_USER_LOG t1
  WHERE calculated gdt_login_date &amp;gt;=today()-30;
QUIT;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;t1.gdt_login_date is still a datetime value and will always be a much larger than today() - 30.&lt;/P&gt;
&lt;P&gt;(seconds from 01jan1960:00:00:00 vs days from 01jan1960)&lt;/P&gt;</description>
      <pubDate>Tue, 07 Mar 2017 11:48:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338771#M22506</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2017-03-07T11:48:16Z</dc:date>
    </item>
    <item>
      <title>Re: Results Viewer - SAS Output Frame is Blank</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338859#M22508</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/120296"&gt;@Ishwarkumar&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;And it is not even showing errors.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;And you haven't shown any actual values for the &lt;FONT face="Courier New"&gt;t1.gdt_login_date variable.&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Mar 2017 15:55:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/date-and-time/m-p/338859#M22508</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2017-03-07T15:55:55Z</dc:date>
    </item>
  </channel>
</rss>

