<?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: State Search Help in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65033#M16071</link>
    <description>&lt;P&gt;thank you for your help.&lt;/P&gt;

&lt;P&gt;another question is, if it is possible to search within this stats output. I have tried many things without success.&lt;/P&gt;

&lt;P&gt;("State UP" OR "State DOWN") | stats first(state) by application | search DOWN&lt;/P&gt;

&lt;P&gt;I don't want the latest DOWN event because in the meantime a UP event could be written into the log, so I would try to catch only the latest State event witch have a DOWN value&lt;/P&gt;

&lt;P&gt;Do you have a clue ?&lt;/P&gt;

&lt;P&gt;Bye&lt;BR /&gt;
Rob&lt;/P&gt;</description>
    <pubDate>Fri, 08 Oct 2010 14:44:38 GMT</pubDate>
    <dc:creator>RobertRi</dc:creator>
    <dc:date>2010-10-08T14:44:38Z</dc:date>
    <item>
      <title>State Search Help</title>
      <link>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65030#M16068</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;

&lt;P&gt;I have a logfile which looks like this:&lt;/P&gt;

&lt;P&gt;%Date %Time %Server %Application %State ("State UP" or "State DOWN")&lt;/P&gt;

&lt;P&gt;If I try to find the last State for App1, i will use this search&lt;/P&gt;

&lt;P&gt;App1 ("State UP" OR "State DOWN") | head 1&lt;/P&gt;

&lt;P&gt;this will result in one event with State UP or DOWN&lt;/P&gt;

&lt;P&gt;My problem now is that there are 50 Apps and I would like to show a list with all 50 Apps and there current states.&lt;/P&gt;

&lt;P&gt;Could you please help me with this search&lt;/P&gt;

&lt;P&gt;Thanks
Rob&lt;/P&gt;</description>
      <pubDate>Wed, 06 Oct 2010 15:53:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65030#M16068</guid>
      <dc:creator>RobertRi</dc:creator>
      <dc:date>2010-10-06T15:53:25Z</dc:date>
    </item>
    <item>
      <title>Re: State Search Help</title>
      <link>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65031#M16069</link>
      <description>&lt;P&gt;I have tried the following which looks good&lt;BR /&gt;
("State UP" OR "State DOWN") | stats first(state) by application&lt;/P&gt;

&lt;P&gt;maybe you have an alternate solution ?&lt;/P&gt;</description>
      <pubDate>Wed, 06 Oct 2010 16:26:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65031#M16069</guid>
      <dc:creator>RobertRi</dc:creator>
      <dc:date>2010-10-06T16:26:31Z</dc:date>
    </item>
    <item>
      <title>Re: State Search Help</title>
      <link>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65032#M16070</link>
      <description>&lt;P&gt;RobertRi,
&lt;/P&gt;&lt;P&gt;
I am not sure from your message if your fields are properly extracted or not. If the fields that contain "Application" and "State" are extracted, then you could do a variety of things including:&lt;/P&gt;

&lt;P&gt;SEARCH: sourcetype=YourSourcetype | table Application,State
SEARCH: sourcetype=YourSourcetype | stats list State by Application&lt;/P&gt;

&lt;P&gt;You should replace YourSourcetype with whatever the proper sourcetype is here.&lt;/P&gt;

&lt;P&gt;You might want to add something like this at the end of your search &lt;I&gt;| sort Application&lt;/I&gt; to alter the order your results are displayed.&lt;/P&gt;

&lt;P&gt;Also, depending on how many events are in your index per Application you might need to do a dedup.&lt;/P&gt;

&lt;P&gt;If your fields are not currently extracted, you should do that first so that the data is more usable.
&lt;/P&gt;&lt;P&gt;Sean&lt;/P&gt;</description>
      <pubDate>Wed, 06 Oct 2010 18:12:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65032#M16070</guid>
      <dc:creator>sdwilkerson</dc:creator>
      <dc:date>2010-10-06T18:12:47Z</dc:date>
    </item>
    <item>
      <title>Re: State Search Help</title>
      <link>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65033#M16071</link>
      <description>&lt;P&gt;thank you for your help.&lt;/P&gt;

&lt;P&gt;another question is, if it is possible to search within this stats output. I have tried many things without success.&lt;/P&gt;

&lt;P&gt;("State UP" OR "State DOWN") | stats first(state) by application | search DOWN&lt;/P&gt;

&lt;P&gt;I don't want the latest DOWN event because in the meantime a UP event could be written into the log, so I would try to catch only the latest State event witch have a DOWN value&lt;/P&gt;

&lt;P&gt;Do you have a clue ?&lt;/P&gt;

&lt;P&gt;Bye&lt;BR /&gt;
Rob&lt;/P&gt;</description>
      <pubDate>Fri, 08 Oct 2010 14:44:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65033#M16071</guid>
      <dc:creator>RobertRi</dc:creator>
      <dc:date>2010-10-08T14:44:38Z</dc:date>
    </item>
    <item>
      <title>Re: State Search Help</title>
      <link>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65034#M16072</link>
      <description>&lt;P&gt;Check my blog post regarding maintaining state:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&lt;A href="http://blogs.splunk.com/2011/01/11/maintaining-state-of-the-union/" target="test_blank"&gt;http://blogs.splunk.com/2011/01/11/maintaining-state-of-the-union/&lt;/A&gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sun, 30 Jan 2011 03:39:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/State-Search-Help/m-p/65034#M16072</guid>
      <dc:creator>araitz</dc:creator>
      <dc:date>2011-01-30T03:39:32Z</dc:date>
    </item>
  </channel>
</rss>

