<?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: Trying to dur2sec a HH field that is more than 24H in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91406#M23512</link>
    <description>&lt;P&gt;You can do it manually;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;blah blah | rex field=your_time_field "(?&amp;lt;HH&amp;gt;\d+):(?&amp;lt;MM&amp;gt;\d+):(?&amp;lt;SS&amp;gt;\d+)" | eval dur = (HH * 3600) + (MM * 60) + SS | table your_time_field dur
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;/K&lt;/P&gt;</description>
    <pubDate>Wed, 09 Oct 2013 20:25:50 GMT</pubDate>
    <dc:creator>kristian_kolb</dc:creator>
    <dc:date>2013-10-09T20:25:50Z</dc:date>
    <item>
      <title>Trying to dur2sec a HH field that is more than 24H</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91405#M23511</link>
      <description>&lt;P&gt;I'm trying to dur2sec a hour field that is more than 24H and therefore doesn't work.  Anyone have any suggestions on how I can get the seconds out of this type of HH:MM:SS?&lt;/P&gt;

&lt;P&gt;Below is a sample output showing that below 24H works fine, everything above fails.&lt;/P&gt;

&lt;P&gt;walltime wall&lt;BR /&gt;
24:00:03&lt;BR /&gt;&lt;BR /&gt;
23:59:46    86386&lt;/P&gt;</description>
      <pubDate>Wed, 09 Oct 2013 19:36:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91405#M23511</guid>
      <dc:creator>wweiland</dc:creator>
      <dc:date>2013-10-09T19:36:40Z</dc:date>
    </item>
    <item>
      <title>Re: Trying to dur2sec a HH field that is more than 24H</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91406#M23512</link>
      <description>&lt;P&gt;You can do it manually;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;blah blah | rex field=your_time_field "(?&amp;lt;HH&amp;gt;\d+):(?&amp;lt;MM&amp;gt;\d+):(?&amp;lt;SS&amp;gt;\d+)" | eval dur = (HH * 3600) + (MM * 60) + SS | table your_time_field dur
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;/K&lt;/P&gt;</description>
      <pubDate>Wed, 09 Oct 2013 20:25:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91406#M23512</guid>
      <dc:creator>kristian_kolb</dc:creator>
      <dc:date>2013-10-09T20:25:50Z</dc:date>
    </item>
    <item>
      <title>Re: Trying to dur2sec a HH field that is more than 24H</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91407#M23513</link>
      <description>&lt;P&gt;I think dur2sec &lt;EM&gt;might&lt;/EM&gt; be aimed at something like a sendmail (x)delay field, where values over 24 hours are converted to days+HH:MM:SS. I'd go with @kristian.kolb 's solution shown below.&lt;/P&gt;</description>
      <pubDate>Wed, 09 Oct 2013 20:32:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91407#M23513</guid>
      <dc:creator>sowings</dc:creator>
      <dc:date>2013-10-09T20:32:02Z</dc:date>
    </item>
    <item>
      <title>Re: Trying to dur2sec a HH field that is more than 24H</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91408#M23514</link>
      <description>&lt;P&gt;Thank you for your help!&lt;/P&gt;</description>
      <pubDate>Wed, 09 Oct 2013 20:42:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91408#M23514</guid>
      <dc:creator>wweiland</dc:creator>
      <dc:date>2013-10-09T20:42:56Z</dc:date>
    </item>
    <item>
      <title>Re: Trying to dur2sec a HH field that is more than 24H</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91409#M23515</link>
      <description>&lt;P&gt;Just want to add, if your timestamp included milliseconds, you can use:&lt;/P&gt;

&lt;P&gt;| rex field=diff "(?\d+):(?\d+):(?\d+).(?\d+)" &lt;BR /&gt;
| eval dur = (HH * 3600) + (MM * 60) + SS + (MS / 1000000) &lt;/P&gt;

&lt;P&gt;my timestamp had 6 decimal places for ms, so I divide ms by 1,000,000&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2019 02:23:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Trying-to-dur2sec-a-HH-field-that-is-more-than-24H/m-p/91409#M23515</guid>
      <dc:creator>wrighke</dc:creator>
      <dc:date>2019-08-01T02:23:57Z</dc:date>
    </item>
  </channel>
</rss>

