<?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 How to search and sort based on dynamic value? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-search-and-sort-based-on-dynamic-value/m-p/624054#M216951</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I am new to splunk and have a requirement where i have to search the logs which are on 100 servers and i have to figure if each log may consist 2 statements as below ex:&lt;/P&gt;
&lt;P&gt;"started step1"&lt;/P&gt;
&lt;P&gt;"started step2"&lt;/P&gt;
&lt;P&gt;source of log contains actual name of source where i can check the step (location of log /test/test1/ABC.log ,/test/test1/CDE.log,/test/test1/DEF.log) which i figured out based on rex command (using regex)&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want a table which contain for each log how many step are completed. like:&lt;/P&gt;
&lt;P&gt;ABC&amp;nbsp; &amp;nbsp; &amp;nbsp; started step1&amp;nbsp;&amp;nbsp;started step2&lt;/P&gt;
&lt;P&gt;CDE&amp;nbsp; &amp;nbsp;&amp;nbsp;started step1&lt;/P&gt;
&lt;P&gt;DEF&amp;nbsp; &amp;nbsp;&amp;nbsp;started step1&amp;nbsp;started step2&lt;/P&gt;</description>
    <pubDate>Tue, 13 Dec 2022 02:44:50 GMT</pubDate>
    <dc:creator>batham</dc:creator>
    <dc:date>2022-12-13T02:44:50Z</dc:date>
    <item>
      <title>How to search and sort based on dynamic value?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-search-and-sort-based-on-dynamic-value/m-p/624054#M216951</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I am new to splunk and have a requirement where i have to search the logs which are on 100 servers and i have to figure if each log may consist 2 statements as below ex:&lt;/P&gt;
&lt;P&gt;"started step1"&lt;/P&gt;
&lt;P&gt;"started step2"&lt;/P&gt;
&lt;P&gt;source of log contains actual name of source where i can check the step (location of log /test/test1/ABC.log ,/test/test1/CDE.log,/test/test1/DEF.log) which i figured out based on rex command (using regex)&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want a table which contain for each log how many step are completed. like:&lt;/P&gt;
&lt;P&gt;ABC&amp;nbsp; &amp;nbsp; &amp;nbsp; started step1&amp;nbsp;&amp;nbsp;started step2&lt;/P&gt;
&lt;P&gt;CDE&amp;nbsp; &amp;nbsp;&amp;nbsp;started step1&lt;/P&gt;
&lt;P&gt;DEF&amp;nbsp; &amp;nbsp;&amp;nbsp;started step1&amp;nbsp;started step2&lt;/P&gt;</description>
      <pubDate>Tue, 13 Dec 2022 02:44:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-search-and-sort-based-on-dynamic-value/m-p/624054#M216951</guid>
      <dc:creator>batham</dc:creator>
      <dc:date>2022-12-13T02:44:50Z</dc:date>
    </item>
    <item>
      <title>Re: Search and sort based on dynamic value</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-search-and-sort-based-on-dynamic-value/m-p/624064#M216953</link>
      <description>&lt;P&gt;Perhaps this will help&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=foo ("started step1" OR "started step2")
```Extract the step into a field```
| rex "(?&amp;lt;step&amp;gt;started step\d)"
```Group the steps by reporting host```
| stats values(step) as steps by host&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 12 Dec 2022 21:02:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-search-and-sort-based-on-dynamic-value/m-p/624064#M216953</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2022-12-12T21:02:19Z</dc:date>
    </item>
    <item>
      <title>Re: Search and sort based on dynamic value</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-search-and-sort-based-on-dynamic-value/m-p/624066#M216954</link>
      <description>&lt;P&gt;Thanks, though while searching in community i find the answer&amp;nbsp;&lt;A href="https://community.splunk.com/t5/Splunk-Search/Combine-multiple-rows-in-one-with-a-common-key/td-p/422336" target="_blank"&gt;https://community.splunk.com/t5/Splunk-Search/Combine-multiple-rows-in-one-with-a-common-key/td-p/422336&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 12 Dec 2022 21:10:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-search-and-sort-based-on-dynamic-value/m-p/624066#M216954</guid>
      <dc:creator>batham</dc:creator>
      <dc:date>2022-12-12T21:10:59Z</dc:date>
    </item>
    <item>
      <title>Re: Search and sort based on dynamic value</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-search-and-sort-based-on-dynamic-value/m-p/624131#M216983</link>
      <description>&lt;P&gt;If your problem is resolved, then please click the "Accept as Solution" button to help future readers.&lt;/P&gt;</description>
      <pubDate>Tue, 13 Dec 2022 13:11:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-search-and-sort-based-on-dynamic-value/m-p/624131#M216983</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2022-12-13T13:11:01Z</dc:date>
    </item>
  </channel>
</rss>

