<?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: Addcoltotals Command Issue in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684055#M233529</link>
    <description>&lt;P&gt;Try without the penultimate search&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;|search MOP=*&lt;/LI-CODE&gt;&lt;P&gt;It isn't necessary as stats by MOP effectively does the same thing i.e. you will only get stats for non-null values of MOP which is what the search is doing as well&lt;/P&gt;</description>
    <pubDate>Fri, 12 Apr 2024 16:30:32 GMT</pubDate>
    <dc:creator>ITWhisperer</dc:creator>
    <dc:date>2024-04-12T16:30:32Z</dc:date>
    <item>
      <title>Addcoltotals Command Issue</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684040#M233522</link>
      <description>&lt;P&gt;Hi Splunkers,&lt;/P&gt;
&lt;P&gt;I am facing weird issue with addcoltotals command. While it is working perfectly fine if i open a new search tab but once i add the same query in Dashboard it is breaking down. I am trying to run the command in SplunkDB connect. Below is the snippet for reference.&lt;BR /&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Not working-After_Adding_to_Dashboard.png" style="width: 999px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/30381iCFD88E7606F44C88/image-size/large?v=v2&amp;amp;px=999" role="button" title="Not working-After_Adding_to_Dashboard.png" alt="Not working-After_Adding_to_Dashboard.png" /&gt;&lt;/span&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Working Fine.png" style="width: 999px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/30380i5F0A5D275D21DB24/image-size/large?v=v2&amp;amp;px=999" role="button" title="Working Fine.png" alt="Working Fine.png" /&gt;&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;Below is the query&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;index=db_connect_dev_data
|rename PROCESS_DT as Date
| table OFFICE,Date,MOP,Total_Volume,Total_Value
| search OFFICE=GB1
|eval _time=strptime(Date,"%Y-%m-%d")
|addinfo
|eval info_min_time=info_min_time-3600,info_max_time=info_max_time-3600
|where _time&amp;gt;=info_min_time AND _time&amp;lt;=info_max_time
|table Date,MOP,OFFICE,Total_Volume,Total_Value
| addcoltotals "Total_Volume" "Total_Value" label=Total_GB1 labelfield=MOP
|filldown
| eval Total_Value_USD=Total_Value/1000000
| eval Total_Value_USD=round(Total_Value_USD,5)
| stats sum(Total_Volume) as "Total_Volume",sum("Total_Value_USD") as Total_Value(mn) by MOP
|search MOP=*
|table MOP,Total_Volume,Total_Value(mn)&lt;/LI-CODE&gt;
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;Let me know if anyone know why it is happening,&lt;/P&gt;</description>
      <pubDate>Fri, 12 Apr 2024 15:59:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684040#M233522</guid>
      <dc:creator>manpreetsingh29</dc:creator>
      <dc:date>2024-04-12T15:59:48Z</dc:date>
    </item>
    <item>
      <title>Re: Addcoltotals Command Issue</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684043#M233523</link>
      <description>&lt;P&gt;What do you mean by "breaking down"?&lt;/P&gt;</description>
      <pubDate>Fri, 12 Apr 2024 15:24:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684043#M233523</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2024-04-12T15:24:30Z</dc:date>
    </item>
    <item>
      <title>Re: Addcoltotals Command Issue</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684053#M233528</link>
      <description>&lt;P&gt;Mean to say not getting the required result.You can find the same in the snippet attached.&lt;/P&gt;</description>
      <pubDate>Fri, 12 Apr 2024 16:14:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684053#M233528</guid>
      <dc:creator>manpreetsingh29</dc:creator>
      <dc:date>2024-04-12T16:14:01Z</dc:date>
    </item>
    <item>
      <title>Re: Addcoltotals Command Issue</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684055#M233529</link>
      <description>&lt;P&gt;Try without the penultimate search&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;|search MOP=*&lt;/LI-CODE&gt;&lt;P&gt;It isn't necessary as stats by MOP effectively does the same thing i.e. you will only get stats for non-null values of MOP which is what the search is doing as well&lt;/P&gt;</description>
      <pubDate>Fri, 12 Apr 2024 16:30:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684055#M233529</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2024-04-12T16:30:32Z</dc:date>
    </item>
    <item>
      <title>Re: Addcoltotals Command Issue</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684064#M233533</link>
      <description>&lt;P&gt;Still facing the same issue. It is intermittent sometime it is working and sometime not.I should get Total_GB1 and total of all column but instead i am getting 18 in place of Total_GB1 and penultimate value is getting printed in 18.&lt;/P&gt;</description>
      <pubDate>Fri, 12 Apr 2024 17:16:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684064#M233533</guid>
      <dc:creator>manpreetsingh29</dc:creator>
      <dc:date>2024-04-12T17:16:39Z</dc:date>
    </item>
    <item>
      <title>Re: Addcoltotals Command Issue</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684178#M233557</link>
      <description>&lt;P&gt;addtotals is the wrong tool for what you wanted. (It is really bad to use screenshot to illustrate text output. &amp;nbsp;Always use text unless you are illustrating a visual effect.) &amp;nbsp;&lt;A href="https://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Addcoltotals" target="_blank" rel="noopener"&gt;addcoltotals&lt;/A&gt; is what you need.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| addcoltotals labelfield=MOP&lt;/LI-CODE&gt;</description>
      <pubDate>Sun, 14 Apr 2024 02:08:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Addcoltotals-Command-Issue/m-p/684178#M233557</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2024-04-14T02:08:15Z</dc:date>
    </item>
  </channel>
</rss>

