<?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: Difference between two times (24hr clock) in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/459633#M270979</link>
    <description>&lt;P&gt;what if EXSTTM=03:38&lt;/P&gt;&lt;P&gt;and EXENTM=03:18 which is on the same day then this code will create problems.&lt;/P&gt;</description>
    <pubDate>Thu, 03 May 2018 12:41:13 GMT</pubDate>
    <dc:creator>kaunth</dc:creator>
    <dc:date>2018-05-03T12:41:13Z</dc:date>
    <item>
      <title>Difference between two times (24hr clock)</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/319603#M270975</link>
      <description>&lt;P&gt;I am using the following syntax&amp;nbsp;to calculate the minutes between two time variable.&lt;/P&gt;&lt;P&gt;INFTIME = INTCK('MINUTE',INPUT(EXSTTM,TIME8.),INPUT(EXENTM,TIME8.));&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;EXSTTM =&amp;nbsp;&lt;/SPAN&gt;23:48&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;EXENTM = 00:48&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;The result is coming out as -1380 but I expect the result to be 60 min obviously. Guess the problem is the end time 00:48 which is the next day. Any suggestion?&lt;/P&gt;</description>
      <pubDate>Fri, 16 Dec 2016 17:42:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/319603#M270975</guid>
      <dc:creator>kaushik_patra</dc:creator>
      <dc:date>2016-12-16T17:42:02Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between two times (24hr clock)</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/319608#M270976</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data have ;
EXSTTM = '23:48't;
EXENTM = '00:48't;
if EXENTM lt EXSTTM then duration=('24:00't-EXSTTM)+EXENTM; 
else duration=intck('minute',EXSTTM,EXENTM);
format EXSTTM EXENTM duration time5.;
run;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 16 Dec 2016 18:17:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/319608#M270976</guid>
      <dc:creator>Jagadishkatam</dc:creator>
      <dc:date>2016-12-16T18:17:07Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between two times (24hr clock)</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/319613#M270977</link>
      <description>&lt;P&gt;Thanks Jag. It worked; I had to do a minor tweak to divide it by 60 as the duration is calculated in seconds and I wanted it to be in minutes.&lt;/P&gt;&lt;P&gt;Kaushik&lt;/P&gt;</description>
      <pubDate>Fri, 16 Dec 2016 18:50:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/319613#M270977</guid>
      <dc:creator>kaushik_patra</dc:creator>
      <dc:date>2016-12-16T18:50:06Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between two times (24hr clock)</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/319616#M270978</link>
      <description>&lt;P&gt;If you are going to compare times across midnight you will need to incorporate a DATE portion, make a datetime value and then you can use intnx function to return minutes between directly using the 'minute' interval.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Dec 2016 19:00:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/319616#M270978</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2016-12-16T19:00:24Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between two times (24hr clock)</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/459633#M270979</link>
      <description>&lt;P&gt;what if EXSTTM=03:38&lt;/P&gt;&lt;P&gt;and EXENTM=03:18 which is on the same day then this code will create problems.&lt;/P&gt;</description>
      <pubDate>Thu, 03 May 2018 12:41:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Difference-between-two-times-24hr-clock/m-p/459633#M270979</guid>
      <dc:creator>kaunth</dc:creator>
      <dc:date>2018-05-03T12:41:13Z</dc:date>
    </item>
  </channel>
</rss>

