<?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 Time calculation in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/time-calculation/m-p/6059947#M1353804</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                              I have to do time calculations in the internal table. I am having 4 fields in my table such as time1,time2,time1_mer and time2_med.In this the values will be stored like this,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;time1-&amp;gt;09:50:48&lt;/P&gt;&lt;P&gt;time2-&amp;gt;06:04:52&lt;/P&gt;&lt;P&gt;time1_mer-&amp;gt;AM&lt;/P&gt;&lt;P&gt;time2_mer-&amp;gt;PM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In this initially i have to do timedifference between time1 and time2. i used ISH_TIME_DIFFERENCE pattern. By this, i am having confusion in giving input in  date1 and date2 fields. i am having s_date in the selection screen.what data i have to pass in the date1 and date2 fields in this pattern. could any one plz tell me how to use this pattern.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 28 Aug 2009 07:12:18 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-08-28T07:12:18Z</dc:date>
    <item>
      <title>Time calculation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/time-calculation/m-p/6059947#M1353804</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                              I have to do time calculations in the internal table. I am having 4 fields in my table such as time1,time2,time1_mer and time2_med.In this the values will be stored like this,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;time1-&amp;gt;09:50:48&lt;/P&gt;&lt;P&gt;time2-&amp;gt;06:04:52&lt;/P&gt;&lt;P&gt;time1_mer-&amp;gt;AM&lt;/P&gt;&lt;P&gt;time2_mer-&amp;gt;PM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In this initially i have to do timedifference between time1 and time2. i used ISH_TIME_DIFFERENCE pattern. By this, i am having confusion in giving input in  date1 and date2 fields. i am having s_date in the selection screen.what data i have to pass in the date1 and date2 fields in this pattern. could any one plz tell me how to use this pattern.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Aug 2009 07:12:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/time-calculation/m-p/6059947#M1353804</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-28T07:12:18Z</dc:date>
    </item>
    <item>
      <title>Re: Time calculation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/time-calculation/m-p/6059948#M1353805</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try this logic:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
DATA: BTIME1 TYPE TIMS, ETIME TYPE TIMS.
CALL FUNCTION 'HRVE_CONVERT_TIME'
     EXPORTING
          TYPE_TIME   = 'B'
          INPUT_TIME  = time1
          INPUT_AM_PM = time1_mer
     IMPORTING
          OUTPUT_TIME = BTIME.
* After this you will have in BTIME time in military format (13:00:00 instead of 01:00:00 PM)
CALL FUNCTION 'HRVE_CONVERT_TIME'
     EXPORTING
          TYPE_TIME   = 'B'
          INPUT_TIME  = time2
          INPUT_AM_PM = time2_mer
     IMPORTING
          OUTPUT_TIME = ETIME.
* After this you will have in ETIME time in military format (13:00:00 instead of 01:00:00 PM)

Here call ISH_TIME_DIFFERENCE with TIME1 = BTIME and TIME2 = ETIME
and you will have result.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Aug 2009 07:55:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/time-calculation/m-p/6059948#M1353805</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-28T07:55:46Z</dc:date>
    </item>
  </channel>
</rss>

