<?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 What field is being matched on? in All Apps and Add-ons</title>
    <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/What-field-is-being-matched-on/m-p/191456#M19630</link>
    <description>&lt;P&gt;I'm running the below splunk search and am getting some confusing results.  &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=access_combined POST | rex field=_raw "(?P&amp;lt;response_time&amp;gt;\d([0-9]{5,5}))" | stats count, min(response_time),max(response_time),avg(response_time),median(response_time),stdev(response_time) by host
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Below are some of the returned results:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;192.168.254.2|-|-|[06/Jun/2014:12:13:03 -0400]|"POST /order/app1/123 HTTP/1.0"|200|284|"-"|"Jakarta Commons-HttpClient"|2802350
192.168.254.2|-|-|[06/Jun/2014:12:13:03 -0400]|"POST /order/app1/123 HTTP/1.0"|200|284|"-"|"Jakarta Commons-HttpClient"|2473207
192.168.254.2|-|-|[06/Jun/2014:12:13:02 -0400]|"POST /order/app1/123 HTTP/1.0"|200|284|"-"|"Jakarta Commons-HttpClient"|3438605
192.168.254.2|-|-|[06/Jun/2014:12:12:46 -0400]|"POST /order/app1/123 HTTP/1.0"|200|284|"-"|"Jakarta Commons-HttpClient"|5334750
192.168.254.2|-|-|[06/Jun/2014:12:12:44 -0400]|"POST /order/app1/123 HTTP/1.0"|200|284|"-"|"Jakarta Commons-HttpClient"|13049640
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Based on the rex I should only be getting results where the field is a 5 digit only character field.  Looking at the results I'm not seeing any 5 character digit only fields.  Last field is the apache response time in microseconds so that's what I'm going for.  Only thing I can think of is it's somehow matching on the date field, but there are special characters in between so I'm not sure how that's possible.&lt;/P&gt;</description>
    <pubDate>Fri, 06 Jun 2014 18:44:50 GMT</pubDate>
    <dc:creator>DFresh4130</dc:creator>
    <dc:date>2014-06-06T18:44:50Z</dc:date>
    <item>
      <title>What field is being matched on?</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/What-field-is-being-matched-on/m-p/191456#M19630</link>
      <description>&lt;P&gt;I'm running the below splunk search and am getting some confusing results.  &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=access_combined POST | rex field=_raw "(?P&amp;lt;response_time&amp;gt;\d([0-9]{5,5}))" | stats count, min(response_time),max(response_time),avg(response_time),median(response_time),stdev(response_time) by host
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Below are some of the returned results:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;192.168.254.2|-|-|[06/Jun/2014:12:13:03 -0400]|"POST /order/app1/123 HTTP/1.0"|200|284|"-"|"Jakarta Commons-HttpClient"|2802350
192.168.254.2|-|-|[06/Jun/2014:12:13:03 -0400]|"POST /order/app1/123 HTTP/1.0"|200|284|"-"|"Jakarta Commons-HttpClient"|2473207
192.168.254.2|-|-|[06/Jun/2014:12:13:02 -0400]|"POST /order/app1/123 HTTP/1.0"|200|284|"-"|"Jakarta Commons-HttpClient"|3438605
192.168.254.2|-|-|[06/Jun/2014:12:12:46 -0400]|"POST /order/app1/123 HTTP/1.0"|200|284|"-"|"Jakarta Commons-HttpClient"|5334750
192.168.254.2|-|-|[06/Jun/2014:12:12:44 -0400]|"POST /order/app1/123 HTTP/1.0"|200|284|"-"|"Jakarta Commons-HttpClient"|13049640
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Based on the rex I should only be getting results where the field is a 5 digit only character field.  Looking at the results I'm not seeing any 5 character digit only fields.  Last field is the apache response time in microseconds so that's what I'm going for.  Only thing I can think of is it's somehow matching on the date field, but there are special characters in between so I'm not sure how that's possible.&lt;/P&gt;</description>
      <pubDate>Fri, 06 Jun 2014 18:44:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/What-field-is-being-matched-on/m-p/191456#M19630</guid>
      <dc:creator>DFresh4130</dc:creator>
      <dc:date>2014-06-06T18:44:50Z</dc:date>
    </item>
    <item>
      <title>Re: What field is being matched on?</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/What-field-is-being-matched-on/m-p/191457#M19631</link>
      <description>&lt;P&gt;I believe you are matching the right field, but not the way you expected.  Try this regex string:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;(?P&amp;lt;response_time&amp;gt;\|\d([0-9]{5,5}$))
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;It should find events with only 5 digits at the end following a pipe.&lt;/P&gt;</description>
      <pubDate>Fri, 06 Jun 2014 18:58:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/What-field-is-being-matched-on/m-p/191457#M19631</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2014-06-06T18:58:32Z</dc:date>
    </item>
  </channel>
</rss>

