<?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: count events in multivalue field in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347421#M102890</link>
    <description>&lt;P&gt;Hih @perlish&lt;/P&gt;

&lt;P&gt;Can you please share events or sample data which causes an error?&lt;/P&gt;</description>
    <pubDate>Tue, 19 Dec 2017 08:03:26 GMT</pubDate>
    <dc:creator>kamlesh_vaghela</dc:creator>
    <dc:date>2017-12-19T08:03:26Z</dc:date>
    <item>
      <title>count events in multivalue field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347415#M102884</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;
    I want to deal the multivalue field to get the counts whch is satisfied the conditions I set. For example, in the following picture, I want to get search result of  (myfield&amp;gt;44) in one event.&lt;BR /&gt;
&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/4010i44315E4821307EF1/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Dec 2017 08:35:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347415#M102884</guid>
      <dc:creator>perlish</dc:creator>
      <dc:date>2017-12-18T08:35:48Z</dc:date>
    </item>
    <item>
      <title>Re: count events in multivalue field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347416#M102885</link>
      <description>&lt;P&gt;try this command&lt;BR /&gt;
| eval n=mvcount(myfield) &lt;/P&gt;</description>
      <pubDate>Mon, 18 Dec 2017 09:13:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347416#M102885</guid>
      <dc:creator>andrey2007</dc:creator>
      <dc:date>2017-12-18T09:13:27Z</dc:date>
    </item>
    <item>
      <title>Re: count events in multivalue field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347417#M102886</link>
      <description>&lt;P&gt;HI&lt;/P&gt;

&lt;P&gt;Can you please try this?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;YOUR_SEARCH
| eval myfield=mvfilter(myfield&amp;gt;44) 
| eval n=mvcount(myfield)
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;My Sample search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| makeresults 
| eval myfield="10,20,30,40" 
| makemv delim="," myfield 
| eval myfield=mvfilter(myfield&amp;gt;20) 
| eval n=mvcount(myfield)
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 18 Dec 2017 09:26:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347417#M102886</guid>
      <dc:creator>kamlesh_vaghela</dc:creator>
      <dc:date>2017-12-18T09:26:12Z</dc:date>
    </item>
    <item>
      <title>Re: count events in multivalue field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347418#M102887</link>
      <description>&lt;P&gt;try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;|eval myfield_count=mvcount(mvfilter(myfield&amp;gt;44))
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 18 Dec 2017 13:07:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347418#M102887</guid>
      <dc:creator>cmerriman</dc:creator>
      <dc:date>2017-12-18T13:07:33Z</dc:date>
    </item>
    <item>
      <title>Re: count events in multivalue field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347419#M102888</link>
      <description>&lt;P&gt;It works,thank you!&lt;BR /&gt;
While I have another question, it seems that splunk parse the float to string sometimes, and because of this problem, the mvfilter function may  become invalid. How can I solve it in this situation?&lt;/P&gt;</description>
      <pubDate>Tue, 19 Dec 2017 04:55:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347419#M102888</guid>
      <dc:creator>perlish</dc:creator>
      <dc:date>2017-12-19T04:55:08Z</dc:date>
    </item>
    <item>
      <title>Re: count events in multivalue field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347420#M102889</link>
      <description>&lt;P&gt;Thanks! It works!&lt;/P&gt;</description>
      <pubDate>Tue, 19 Dec 2017 04:56:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347420#M102889</guid>
      <dc:creator>perlish</dc:creator>
      <dc:date>2017-12-19T04:56:24Z</dc:date>
    </item>
    <item>
      <title>Re: count events in multivalue field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347421#M102890</link>
      <description>&lt;P&gt;Hih @perlish&lt;/P&gt;

&lt;P&gt;Can you please share events or sample data which causes an error?&lt;/P&gt;</description>
      <pubDate>Tue, 19 Dec 2017 08:03:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347421#M102890</guid>
      <dc:creator>kamlesh_vaghela</dc:creator>
      <dc:date>2017-12-19T08:03:26Z</dc:date>
    </item>
    <item>
      <title>Re: count events in multivalue field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347422#M102891</link>
      <description>&lt;P&gt;I'm sorry that I don't have the sample data. When I tried to solve the question I asked ,I used nomv() method and found that the single value's type is string. Therefore, I asked the following question.&lt;/P&gt;</description>
      <pubDate>Wed, 20 Dec 2017 01:41:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-events-in-multivalue-field/m-p/347422#M102891</guid>
      <dc:creator>perlish</dc:creator>
      <dc:date>2017-12-20T01:41:52Z</dc:date>
    </item>
  </channel>
</rss>

