<?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: replacing large numeric values with 0 in Reporting</title>
    <link>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507045#M8165</link>
    <description>&lt;UL&gt;&lt;LI&gt;&lt;STRONG&gt;mvmap&amp;nbsp;&lt;/STRONG&gt;can work over splunk ver 8.&lt;/LI&gt;&lt;LI&gt;I see your query. but I'm not sure why&amp;nbsp;&lt;STRONG&gt; xTemp_wl0&amp;nbsp;&lt;/STRONG&gt;is multi value.&lt;/LI&gt;&lt;LI&gt;try &lt;STRONG&gt;| rex field=xTemp_wl0 mode=sed "s/\d{3,}/0/g"&amp;nbsp;&lt;/STRONG&gt;and&amp;nbsp;&lt;STRONG&gt;| stats avg(xTemp_wl0)&lt;/STRONG&gt;&lt;/LI&gt;&lt;/UL&gt;</description>
    <pubDate>Thu, 02 Jul 2020 11:16:09 GMT</pubDate>
    <dc:creator>to4kawa</dc:creator>
    <dc:date>2020-07-02T11:16:09Z</dc:date>
    <item>
      <title>replacing large numeric values with 0</title>
      <link>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/506985#M8158</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have a dataset with column name as&amp;nbsp; WiFi_txop0&amp;nbsp; and values as 48,54,76,78,87,77,254311,65,99,65,..........&lt;/P&gt;&lt;P&gt;I want to replace the value of 254311 as 0 so that i could get a good average. I am using following query.&lt;/P&gt;&lt;P&gt;index=mmm&lt;/P&gt;&lt;P&gt;| stats avg(aWiFi_txop0) as WiFi_txop0&lt;/P&gt;&lt;P&gt;| eval WiFi_txop0_new = if(WiFi_txop0 &amp;gt; 100, 0, WiFi_txop0)&lt;BR /&gt;| eval usage_percent = round(WiFi_txop0_new,0)&lt;BR /&gt;| fields + usage_percent&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But i am not getting result as 0.&lt;/P&gt;&lt;P&gt;Please help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jul 2020 07:45:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/506985#M8158</guid>
      <dc:creator>sanjeev</dc:creator>
      <dc:date>2020-07-02T07:45:52Z</dc:date>
    </item>
    <item>
      <title>Re: replacing large numeric values with 0</title>
      <link>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/506987#M8159</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/223244"&gt;@sanjeev&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;Is that a multi value field?&lt;/P&gt;&lt;P&gt;If not try converting to a number using &lt;FONT color="#FF6600"&gt;tonumber&lt;/FONT&gt; and compare&lt;/P&gt;&lt;P&gt;Below search is working fine&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;|makeresults|eval value="48,54,76,78,87,77,254311,65,99,65"|makemv value delim=","|mvexpand value
|eval newValue=if(value&amp;gt;100,0,value)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jul 2020 07:58:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/506987#M8159</guid>
      <dc:creator>renjith_nair</dc:creator>
      <dc:date>2020-07-02T07:58:13Z</dc:date>
    </item>
    <item>
      <title>Re: replacing large numeric values with 0</title>
      <link>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/506994#M8160</link>
      <description>&lt;P&gt;Yes it is muti value column&amp;nbsp; with more than million values.&lt;/P&gt;&lt;P&gt;sample of few values&lt;/P&gt;&lt;TABLE width="79"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="79"&gt;xTemp_wl0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;48&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;50&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;43&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;60&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;60&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;54&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;61&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;60&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1161181233&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;43&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;60&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;49&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jul 2020 08:30:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/506994#M8160</guid>
      <dc:creator>sanjeev</dc:creator>
      <dc:date>2020-07-02T08:30:50Z</dc:date>
    </item>
    <item>
      <title>Re: replacing large numeric values with 0</title>
      <link>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507014#M8161</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/223244"&gt;@sanjeev&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;If it's a multi value column, you can use &lt;FONT color="#FF9900"&gt;mvmap&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;|eval newValue=mvmap(xTemp_wl0,if(xTemp_wl0%100!=xTemp_wl0,0,xTemp_wl0))&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Or you can &lt;FONT color="#FF9900"&gt;mvexpand &lt;FONT color="#000000"&gt;and do the comparison operation but that would be bit more resource expensive for a million records&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jul 2020 09:48:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507014#M8161</guid>
      <dc:creator>renjith_nair</dc:creator>
      <dc:date>2020-07-02T09:48:39Z</dc:date>
    </item>
    <item>
      <title>Re: replacing large numeric values with 0</title>
      <link>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507031#M8162</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| makeresults | eval _raw="xTemp_wl0
48
50
43
60
60
54
61
60
1161181233
43
60
49"
| multikv forceheader=1
| stats list(xTemp_wl0) as xTemp_wl0
| table xTemp_wl0

| eventstats avg(eval(mvmap(xTemp_wl0,if(xTemp_wl0&amp;gt;100,0,xTemp_wl0)))) as average&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="107px" height="25px"&gt;&lt;DIV class="multivalue-subcell"&gt;&lt;DIV class="multivalue-subcell"&gt;&amp;nbsp;&lt;SPAN&gt;xTemp_wl0&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/TD&gt;&lt;TD width="72px" height="25px"&gt;&amp;nbsp;average&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="107px" height="267px"&gt;&lt;DIV class="multivalue-subcell"&gt;48&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;50&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;43&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;60&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;60&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;54&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;61&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;60&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;1161181233&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;43&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;60&lt;/DIV&gt;&lt;DIV class="multivalue-subcell"&gt;49&lt;/DIV&gt;&lt;/TD&gt;&lt;TD width="72px" height="267px"&gt;49&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jul 2020 10:36:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507031#M8162</guid>
      <dc:creator>to4kawa</dc:creator>
      <dc:date>2020-07-02T10:36:50Z</dc:date>
    </item>
    <item>
      <title>Re: replacing large numeric values with 0</title>
      <link>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507042#M8163</link>
      <description>&lt;P&gt;index=metrics HCTELEM AND (deviceid=B2* OR deviceid =B3*)&lt;BR /&gt;| fields + mac uptime deviceid payload version&lt;BR /&gt;| eval payload = replace(payload, "\"\"", "\"")&lt;BR /&gt;| spath input=payload output=Temp_wl0 path=Temp{0}&lt;BR /&gt;| spath input=payload output=Temp_wl1 path=Temp{1}&lt;BR /&gt;| spath input=payload output=Mem0 path=Mem{0}&lt;BR /&gt;| spath input=payload output=Mem1 path=Mem{1}&lt;BR /&gt;| spath input=payload output=CPU0 path=CPU{0}&lt;BR /&gt;| spath input=payload output=CPU1 path=CPU{1}&lt;BR /&gt;| spath input=payload output=CPU2 path=CPU{2}&lt;BR /&gt;| spath input=payload output=WiFi_txop0 path=WiFi{}.txop{0}&lt;BR /&gt;| spath input=payload output=WiFi_txop1 path=WiFi{}.txop{1}&lt;BR /&gt;| spath input=payload output=DSL_Bearer0_Up path=DSL{}.Bearer{}.0{}.UpDn{0}&lt;BR /&gt;| spath input=payload output=DSL_Bearer0_Dn path=DSL{}.Bearer{}.0{}.UpDn{1}&lt;BR /&gt;| spath input=payload output=DSL_Bearer0_RsUnCorr0 path=DSL{}.Bearer{}.0{}.RsUnCorr{0}&lt;BR /&gt;| spath input=payload output=DSL_Bearer0_RsUnCorr1 path=DSL{}.Bearer{}.0{}.RsUnCorr{1}&lt;BR /&gt;| spath input=payload output=DSL_MaxUp path=DSL{}.MaxUpDn{0}&lt;BR /&gt;| spath input=payload output=DSL_MaxDn path=DSL{}.MaxUpDn{1}&lt;BR /&gt;| spath input=payload output=DSL_Retrain path=DSL{}.Retrain&lt;BR /&gt;| spath input=payload output=DSL_CRC0 path=DSL{}.CRC{0}&lt;BR /&gt;| spath input=payload output=DSL_CRC1 path=DSL{}.CRC{1}&lt;BR /&gt;| spath input=payload output=DSL_ES0 path=DSL{}.ES{0}&lt;BR /&gt;| spath input=payload output=DSL_ES1 path=DSL{}.ES{1}&lt;BR /&gt;| spath input=payload output=DSL_SES0 path=DSL{}.SES{0}&lt;BR /&gt;| spath input=payload output=DSL_SES1 path=DSL{}.SES{1}&lt;BR /&gt;| spath input=payload output=Eth0_LinkUp path=Eth{}.0{}.LinkUp&lt;BR /&gt;| spath input=payload output=Eth0_Type path=Eth{}.0{}.Type&lt;BR /&gt;| spath input=payload output=Eth1_LinkUp path=Eth{}.1{}.LinkUp&lt;BR /&gt;| spath input=payload output=Eth1_Type path=Eth{}.1{}.Type&lt;BR /&gt;| stats max(_time) as max_time min(_time) as min_time max(deviceid) as deviceid latest(version) as version count as number_of_metrics latest(_time) as _time latest(uptime) as uptime&lt;BR /&gt;max(CPU0) as xCPU0 max(CPU1) as xCPU1 max(CPU2) as xCPU2 max(Mem0) as xMem0 max(Mem1) as xMem1 max(WiFi_txop0) as xWiFi_txop0 max(WiFi_txop1) as xWiFi_txop1 max(DSL_MaxUp) as xDSL_MaxUp max(DSL_MaxDn) as xDSL_MaxDn max(Temp_wl0) as xTemp_wl0 max(Temp_wl1) as xTemp_wl1&lt;BR /&gt;min(CPU0) as mCPU0 min(CPU1) as mCPU1 min(CPU2) as mCPU2 min(Mem0) as mMem0 min(Mem1) as mMem1 min(WiFi_txop0) as mWiFi_txop0 min(WiFi_txop1) as mWiFi_txop1 min(DSL_MaxUp) as mDSL_MaxUp min(DSL_MaxDn) as mDSL_MaxDn min(Temp_wl0) as mTemp_wl0 min(Temp_wl1) as mTemp_wl1&lt;BR /&gt;avg(CPU0) as aCPU0 avg(CPU1) as aCPU1 avg(CPU2) as aCPU2 avg(Mem0) as aMem0 avg(Mem1) as aMem1 avg(WiFi_txop0) as aWiFi_txop0 avg(WiFi_txop1) as aWiFi_txop1 avg(DSL_MaxUp) as aDSL_MaxUp avg(DSL_MaxDn) as aDSL_MaxDn avg(Temp_wl0) as aTemp_wl0 avg(Temp_wl1) as aTemp_wl1&lt;BR /&gt;max(Eth*) as Eth* last(DSL_Retrain) as DSL_Retrain max(DSL_Bearer0_RsUnCorr0) as xDSL_Bearer0_RsUnCorr0 min(DSL_Bearer0_RsUnCorr0) as mDSL_Bearer0_RsUnCorr0 by mac&lt;/P&gt;&lt;P&gt;| makeresults | eval _raw="xTemp_wl0" | multikv forceheader=1&lt;BR /&gt;| stats list(xTemp_wl0) as xTemp_wl0&lt;BR /&gt;| table xTemp_wl0&lt;BR /&gt;| eventstats avg(eval(mvmap(xTemp_wl0,if(xTemp_wl0&amp;gt;100,0,xTemp_wl0)))) as average&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the full Query. The data is in Json format so i have parsed it. but unable to get the average.&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is also giving error as -&amp;nbsp;Error in 'eventstats' command: The eval expression for dynamic field 'eval(mvmap(xTemp_wl0,if(xTemp_wl0&amp;gt;100,0,xTemp_wl0)))' is invalid. Error='The 'mvmap' function is unsupported or undefined.'.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/184221"&gt;@to4kawa&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jul 2020 10:57:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507042#M8163</guid>
      <dc:creator>sanjeev</dc:creator>
      <dc:date>2020-07-02T10:57:42Z</dc:date>
    </item>
    <item>
      <title>Re: replacing large numeric values with 0</title>
      <link>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507043#M8164</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/136781"&gt;@renjith_nair&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is giving error as&amp;nbsp;Error='The 'mvmap' function is unsupported or undefined.'.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jul 2020 10:58:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507043#M8164</guid>
      <dc:creator>sanjeev</dc:creator>
      <dc:date>2020-07-02T10:58:40Z</dc:date>
    </item>
    <item>
      <title>Re: replacing large numeric values with 0</title>
      <link>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507045#M8165</link>
      <description>&lt;UL&gt;&lt;LI&gt;&lt;STRONG&gt;mvmap&amp;nbsp;&lt;/STRONG&gt;can work over splunk ver 8.&lt;/LI&gt;&lt;LI&gt;I see your query. but I'm not sure why&amp;nbsp;&lt;STRONG&gt; xTemp_wl0&amp;nbsp;&lt;/STRONG&gt;is multi value.&lt;/LI&gt;&lt;LI&gt;try &lt;STRONG&gt;| rex field=xTemp_wl0 mode=sed "s/\d{3,}/0/g"&amp;nbsp;&lt;/STRONG&gt;and&amp;nbsp;&lt;STRONG&gt;| stats avg(xTemp_wl0)&lt;/STRONG&gt;&lt;/LI&gt;&lt;/UL&gt;</description>
      <pubDate>Thu, 02 Jul 2020 11:16:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507045#M8165</guid>
      <dc:creator>to4kawa</dc:creator>
      <dc:date>2020-07-02T11:16:09Z</dc:date>
    </item>
    <item>
      <title>Re: replacing large numeric values with 0</title>
      <link>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507054#M8166</link>
      <description>&lt;P&gt;Thanks a lot&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/184221"&gt;@to4kawa&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is working.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks once again.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jul 2020 11:47:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/replacing-large-numeric-values-with-0/m-p/507054#M8166</guid>
      <dc:creator>sanjeev</dc:creator>
      <dc:date>2020-07-02T11:47:14Z</dc:date>
    </item>
  </channel>
</rss>

