<?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 of character in field in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/count-of-character-in-field/m-p/50760#M12212</link>
    <description>&lt;P&gt;How about something like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=access_combined | eval chars=mvcount(split(uri, "=")) - 1 | table uri, chars
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Fri, 29 Jul 2011 20:06:14 GMT</pubDate>
    <dc:creator>mw</dc:creator>
    <dc:date>2011-07-29T20:06:14Z</dc:date>
    <item>
      <title>count of character in field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-of-character-in-field/m-p/50758#M12210</link>
      <description>&lt;P&gt;how would I count the number of occurances of a character or symbol in an extracted field and display that as a seperate field?&lt;/P&gt;

&lt;P&gt;for instance counting the number fields passed in a POST message? (delimited by &lt;span class="lia-unicode-emoji" title=":grinning_face_with_big_eyes:"&gt;😃&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;i have looked at rex, mvcount and stats but so far havent come up with a solution to do it from a search.&lt;/P&gt;

&lt;P&gt;Any ideas?&lt;/P&gt;</description>
      <pubDate>Fri, 29 Jul 2011 19:48:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-of-character-in-field/m-p/50758#M12210</guid>
      <dc:creator>EricPartington</dc:creator>
      <dc:date>2011-07-29T19:48:04Z</dc:date>
    </item>
    <item>
      <title>Re: count of character in field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-of-character-in-field/m-p/50759#M12211</link>
      <description>&lt;P&gt;there's probably more than way to do it with the &lt;CODE&gt;eval&lt;/CODE&gt; command. &lt;/P&gt;

&lt;P&gt;&lt;A href="http://www.splunk.com/base/Documentation/latest/SearchReference/CommonEvalFunctions"&gt;http://www.splunk.com/base/Documentation/latest/SearchReference/CommonEvalFunctions&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Here's one, if you have a field called 'postPayload': &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;your search&amp;gt; | eval numArgs = mvcount(split(postPayload,"="))-1
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 29 Jul 2011 19:59:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-of-character-in-field/m-p/50759#M12211</guid>
      <dc:creator>sideview</dc:creator>
      <dc:date>2011-07-29T19:59:49Z</dc:date>
    </item>
    <item>
      <title>Re: count of character in field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/count-of-character-in-field/m-p/50760#M12212</link>
      <description>&lt;P&gt;How about something like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=access_combined | eval chars=mvcount(split(uri, "=")) - 1 | table uri, chars
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 29 Jul 2011 20:06:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/count-of-character-in-field/m-p/50760#M12212</guid>
      <dc:creator>mw</dc:creator>
      <dc:date>2011-07-29T20:06:14Z</dc:date>
    </item>
  </channel>
</rss>

