<?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 get a Stats count of field values by country in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-Stats-count-of-field-values-by-country/m-p/174558#M50093</link>
    <description>&lt;P&gt;Hi Hildoceras,&lt;/P&gt;

&lt;P&gt;something like this should get you there:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; ... | stats count(eval(method="POST")) AS post count(eval(method="GET")) AS get count(eval(method="HEAD")) AS head by country | addtotals 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;hope this helps ...&lt;/P&gt;

&lt;P&gt;cheers, MuS&lt;/P&gt;</description>
    <pubDate>Wed, 05 Mar 2014 10:32:37 GMT</pubDate>
    <dc:creator>MuS</dc:creator>
    <dc:date>2014-03-05T10:32:37Z</dc:date>
    <item>
      <title>How to get a Stats count of field values by country</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-Stats-count-of-field-values-by-country/m-p/174557#M50092</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;

&lt;P&gt;I am looking at access log data with the fields src_ip and method (get, post, head)&lt;/P&gt;

&lt;P&gt;I have been running the search src_ip="*" | iplocation src_ip | stats count by country&lt;/P&gt;

&lt;P&gt;this gives me an event count by country.&lt;/P&gt;

&lt;P&gt;I would like to take this further and also get a count of total events by country and a split per country of get, post and head&lt;/P&gt;

&lt;P&gt;any help appreciated&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 16:02:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-Stats-count-of-field-values-by-country/m-p/174557#M50092</guid>
      <dc:creator>Hildoceras</dc:creator>
      <dc:date>2020-09-28T16:02:45Z</dc:date>
    </item>
    <item>
      <title>Re: How to get a Stats count of field values by country</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-Stats-count-of-field-values-by-country/m-p/174558#M50093</link>
      <description>&lt;P&gt;Hi Hildoceras,&lt;/P&gt;

&lt;P&gt;something like this should get you there:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; ... | stats count(eval(method="POST")) AS post count(eval(method="GET")) AS get count(eval(method="HEAD")) AS head by country | addtotals 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;hope this helps ...&lt;/P&gt;

&lt;P&gt;cheers, MuS&lt;/P&gt;</description>
      <pubDate>Wed, 05 Mar 2014 10:32:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-Stats-count-of-field-values-by-country/m-p/174558#M50093</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2014-03-05T10:32:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to get a Stats count of field values by country</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-Stats-count-of-field-values-by-country/m-p/174559#M50094</link>
      <description>&lt;P&gt;Worked like a charm many thanks&lt;/P&gt;</description>
      <pubDate>Wed, 05 Mar 2014 10:46:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-Stats-count-of-field-values-by-country/m-p/174559#M50094</guid>
      <dc:creator>Hildoceras</dc:creator>
      <dc:date>2014-03-05T10:46:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to get a Stats count of field values by country</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-Stats-count-of-field-values-by-country/m-p/174560#M50095</link>
      <description>&lt;P&gt;feel free to accept the answer, thanks &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 05 Mar 2014 11:30:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-Stats-count-of-field-values-by-country/m-p/174560#M50095</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2014-03-05T11:30:25Z</dc:date>
    </item>
  </channel>
</rss>

