<?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: How to Add multiple field values for the matching value of another field in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-Add-multiple-field-values-for-the-matching-value-of/m-p/605285#M210479</link>
    <description>&lt;P&gt;Try this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eval finish_time_epoch = strptime(FINISH_TIME, "%Y-%m-%d %H:%M:%S")
| eval start_time_epoch = strptime(START_TIME, "%Y-%m-%d %H:%M:%S")
| eval duration = finish_time_epoch - start_time_epoch
| stats sum(duration) as duration by finish_time_epoch
| sort - finish_time_epoch
| eval TimeDate=strftime(finish_time_epoch, "%Y-%m-%d %H:%M:%S")
| eval duration=tostring(duration,"duration")
| table duration TimeDate&lt;/LI-CODE&gt;</description>
    <pubDate>Tue, 12 Jul 2022 10:47:09 GMT</pubDate>
    <dc:creator>ITWhisperer</dc:creator>
    <dc:date>2022-07-12T10:47:09Z</dc:date>
    <item>
      <title>How to Add multiple field values for the matching value of another field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-Add-multiple-field-values-for-the-matching-value-of/m-p/605280#M210476</link>
      <description>&lt;P&gt;I want to create a query, that&amp;nbsp; would combine all the duration values into one by adding them for each Time Date.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Edwin1471_0-1657620145156.png" style="width: 823px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/20491iB8DA60257CEC1AE0/image-dimensions/823x381?v=v2" width="823" height="381" role="button" title="Edwin1471_0-1657620145156.png" alt="Edwin1471_0-1657620145156.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;The result should look something like this :&amp;nbsp;&lt;/P&gt;&lt;P&gt;Duration&amp;nbsp; &amp;nbsp; &amp;nbsp; |&amp;nbsp; &amp;nbsp; TimeDate&lt;/P&gt;&lt;P&gt;03:59:18&amp;nbsp; &amp;nbsp; &amp;nbsp; |&amp;nbsp; &amp;nbsp; 2022-07-31&lt;/P&gt;&lt;P&gt;.........&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;|&amp;nbsp; &amp;nbsp; 2022-06-30&lt;/P&gt;&lt;P&gt;........&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; |&amp;nbsp; &amp;nbsp; 2022-05-30&amp;nbsp;&lt;/P&gt;&lt;P&gt;and so on&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 12 Jul 2022 10:14:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-Add-multiple-field-values-for-the-matching-value-of/m-p/605280#M210476</guid>
      <dc:creator>Edwin1471</dc:creator>
      <dc:date>2022-07-12T10:14:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to Add multiple field values for the matching value of another field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-Add-multiple-field-values-for-the-matching-value-of/m-p/605282#M210477</link>
      <description>&lt;P&gt;Were the durations originally in seconds as this would make it easier&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| stats sum(duration_in_seconds) as duration_in_seconds by TimeDate
| fieldformat duration_in_seconds=tostring(duration_in_seconds,"duration")&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 12 Jul 2022 10:27:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-Add-multiple-field-values-for-the-matching-value-of/m-p/605282#M210477</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-07-12T10:27:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to Add multiple field values for the matching value of another field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-Add-multiple-field-values-for-the-matching-value-of/m-p/605284#M210478</link>
      <description>&lt;P&gt;No&amp;nbsp;&lt;/P&gt;&lt;P&gt;The initial query&amp;nbsp;&lt;/P&gt;&lt;P&gt;| eval finish_time_epoch = strptime(FINISH_TIME, "%Y-%m-%d %H:%M:%S")&lt;BR /&gt;| eval start_time_epoch = strptime(START_TIME, "%Y-%m-%d %H:%M:%S")&lt;BR /&gt;| eval duration = tostring((finish_time_epoch - start_time_epoch), "duration")&lt;BR /&gt;| rex field="duration" mode=sed "s/\..*$//"&lt;BR /&gt;| sort -FINISH_TIME&lt;BR /&gt;| table duration, timeDate&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 12 Jul 2022 10:39:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-Add-multiple-field-values-for-the-matching-value-of/m-p/605284#M210478</guid>
      <dc:creator>Edwin1471</dc:creator>
      <dc:date>2022-07-12T10:39:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to Add multiple field values for the matching value of another field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-Add-multiple-field-values-for-the-matching-value-of/m-p/605285#M210479</link>
      <description>&lt;P&gt;Try this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eval finish_time_epoch = strptime(FINISH_TIME, "%Y-%m-%d %H:%M:%S")
| eval start_time_epoch = strptime(START_TIME, "%Y-%m-%d %H:%M:%S")
| eval duration = finish_time_epoch - start_time_epoch
| stats sum(duration) as duration by finish_time_epoch
| sort - finish_time_epoch
| eval TimeDate=strftime(finish_time_epoch, "%Y-%m-%d %H:%M:%S")
| eval duration=tostring(duration,"duration")
| table duration TimeDate&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 12 Jul 2022 10:47:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-Add-multiple-field-values-for-the-matching-value-of/m-p/605285#M210479</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-07-12T10:47:09Z</dc:date>
    </item>
  </channel>
</rss>

