<?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 do I filter event by specifiing bytes&amp;gt;(1024*10), having simple calculation on the right side of the field? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-filter-event-by-specifiing-bytes-gt-1024-10-having/m-p/74003#M15136</link>
    <description>&lt;P&gt;Hi&lt;/P&gt;

&lt;P&gt;Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=access* | where bytes&amp;gt;1024*10
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;To verify your it is working you can try this search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; sourcetype=access*|where bytes&amp;gt;10*1024 | table bytes | sort bytes
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Fri, 28 Sep 2012 06:25:55 GMT</pubDate>
    <dc:creator>chris</dc:creator>
    <dc:date>2012-09-28T06:25:55Z</dc:date>
    <item>
      <title>How do I filter event by specifiing bytes&gt;(1024*10), having simple calculation on the right side of the field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-filter-event-by-specifiing-bytes-gt-1024-10-having/m-p/74002#M15135</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I am trying to search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=access* bytes&amp;gt;1024*10
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;But this returns event bytes less than 1024, and the result looks wrong.&lt;BR /&gt;
Is there anyway to add calculation on the right side of field?&lt;/P&gt;

&lt;P&gt;Thank you,&lt;/P&gt;</description>
      <pubDate>Fri, 28 Sep 2012 05:57:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-filter-event-by-specifiing-bytes-gt-1024-10-having/m-p/74002#M15135</guid>
      <dc:creator>melonman</dc:creator>
      <dc:date>2012-09-28T05:57:24Z</dc:date>
    </item>
    <item>
      <title>Re: How do I filter event by specifiing bytes&gt;(1024*10), having simple calculation on the right side of the field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-filter-event-by-specifiing-bytes-gt-1024-10-having/m-p/74003#M15136</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;

&lt;P&gt;Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=access* | where bytes&amp;gt;1024*10
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;To verify your it is working you can try this search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; sourcetype=access*|where bytes&amp;gt;10*1024 | table bytes | sort bytes
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 28 Sep 2012 06:25:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-filter-event-by-specifiing-bytes-gt-1024-10-having/m-p/74003#M15136</guid>
      <dc:creator>chris</dc:creator>
      <dc:date>2012-09-28T06:25:55Z</dc:date>
    </item>
    <item>
      <title>Re: How do I filter event by specifiing bytes&gt;(1024*10), having simple calculation on the right side of the field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-do-I-filter-event-by-specifiing-bytes-gt-1024-10-having/m-p/74004#M15137</link>
      <description>&lt;P&gt;You can use the &lt;CODE&gt;where&lt;/CODE&gt; search command:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=access* | where bytes&amp;gt;1024*10
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Or, you can create a macro in macros.conf:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[evaluate(1)]
args = x
definition = tostring($x$)
iseval = true
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Once you have this macro defined and scoped for your app, you can do this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=access* bytes &amp;gt; `evaluate(1024*10)`
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;In some circumstances (which are rare, and probably not applicable in your case) in newer versions of Splunk, the latter may perform considerably faster. In most cases, though, it will be about the same.&lt;/P&gt;</description>
      <pubDate>Fri, 28 Sep 2012 06:59:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-do-I-filter-event-by-specifiing-bytes-gt-1024-10-having/m-p/74004#M15137</guid>
      <dc:creator>gkanapathy</dc:creator>
      <dc:date>2012-09-28T06:59:56Z</dc:date>
    </item>
  </channel>
</rss>

