<?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 to place commas in the output of a chart with columns that varies depending on the search in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237583#M70596</link>
    <description>&lt;P&gt;Try this &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=indexname | eval YMD=strftime(_time,"%Y-%m-%d") | chart sum(eval(round((PRODUCT*2.5),2))) over TYPE by YMD useother=f limit=500 | addtotals col=true 2016- labelfield=TYPE label="Product Type Totals" fieldname="Totals" |  foreach * [eval &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;=if("&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;" == "YMD", &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;, tostring('&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;', "commas")))]
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Tue, 05 Jul 2016 11:27:07 GMT</pubDate>
    <dc:creator>sundareshr</dc:creator>
    <dc:date>2016-07-05T11:27:07Z</dc:date>
    <item>
      <title>how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237576#M70589</link>
      <description>&lt;P&gt;how to place commas in the output of a chart with columns that varies depending on the search (example is date).  Sample search would be index=indexname | chart count(fieldname) over xfieldname by date_mday. Results are numerals which i intend to place commas as a thousands separator but was unable to do so because i do not know how would i command a tostring to a variable column name. please help.&lt;/P&gt;</description>
      <pubDate>Mon, 04 Jul 2016 14:54:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237576#M70589</guid>
      <dc:creator>jonathan_yan5</dc:creator>
      <dc:date>2016-07-04T14:54:13Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237577#M70590</link>
      <description>&lt;P&gt;Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | foreach * [eval &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;=if("&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;" == "date_mday", &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;, tostring(round('&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;', 2), "commas")))]
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 04 Jul 2016 15:11:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237577#M70590</guid>
      <dc:creator>sundareshr</dc:creator>
      <dc:date>2016-07-04T15:11:12Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237578#M70591</link>
      <description>&lt;P&gt;First of all, DO NOT use the "free" (but &lt;EM&gt;always&lt;/EM&gt; wrong) &lt;CODE&gt;date_*&lt;/CODE&gt; fields, calculate your own like this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | eval date_mday = strftime(_time, "%d")
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;As far as commas, do this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;...| foreach * [ eval &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;= if(isnum($&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;$), tostring($&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;$, "commas"), $&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;$) ]
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 04 Jul 2016 15:39:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237578#M70591</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2016-07-04T15:39:41Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237579#M70592</link>
      <description>&lt;P&gt;did not seem to get the solution applying the above formula. here is my search:&lt;/P&gt;

&lt;P&gt;index=indexname | eval YMD=strftime(_time,"%Y-%m-%d")  | chart eval(round(count(PRODUCT)&lt;EM&gt;2.5,2)) over TYPE by YMD useother=f limit=500 | addtotals col=true 2016-&lt;/EM&gt; labelfield=TYPE label="Product Type Totals" fieldname="Totals"&lt;/P&gt;

&lt;P&gt;i need to place commas on all numeric values inside columns and totals&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jul 2016 11:08:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237579#M70592</guid>
      <dc:creator>jonathan_yan5</dc:creator>
      <dc:date>2016-07-05T11:08:53Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237580#M70593</link>
      <description>&lt;P&gt;did not seem to get the solution applying the above formula. here is my search:&lt;/P&gt;

&lt;P&gt;index=indexname | eval YMD=strftime(_time,"%Y-%m-%d")  | chart eval(round(count(PRODUCT)&lt;EM&gt;2.5,2)) over TYPE by YMD useother=f limit=500 | addtotals col=true 2016-&lt;/EM&gt; labelfield=TYPE label="Product Type Totals" fieldname="Totals"&lt;/P&gt;

&lt;P&gt;i need to place commas on all numeric values inside columns and totals&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jul 2016 11:09:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237580#M70593</guid>
      <dc:creator>jonathan_yan5</dc:creator>
      <dc:date>2016-07-05T11:09:00Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237581#M70594</link>
      <description>&lt;P&gt;to add, the sum of "tostring" values when adding commas are not reflected on totals&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jul 2016 11:10:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237581#M70594</guid>
      <dc:creator>jonathan_yan5</dc:creator>
      <dc:date>2016-07-05T11:10:42Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237582#M70595</link>
      <description>&lt;P&gt;to add, the sum of "tostring" values when adding commas are not reflected on totals&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jul 2016 11:10:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237582#M70595</guid>
      <dc:creator>jonathan_yan5</dc:creator>
      <dc:date>2016-07-05T11:10:47Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237583#M70596</link>
      <description>&lt;P&gt;Try this &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=indexname | eval YMD=strftime(_time,"%Y-%m-%d") | chart sum(eval(round((PRODUCT*2.5),2))) over TYPE by YMD useother=f limit=500 | addtotals col=true 2016- labelfield=TYPE label="Product Type Totals" fieldname="Totals" |  foreach * [eval &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;=if("&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;" == "YMD", &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;, tostring('&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;', "commas")))]
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 05 Jul 2016 11:27:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237583#M70596</guid>
      <dc:creator>sundareshr</dc:creator>
      <dc:date>2016-07-05T11:27:07Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237584#M70597</link>
      <description>&lt;P&gt;I just tried it (again) and it worked perfectly.   Try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=indexname | eval YMD=strftime(_time,"%Y-%m-%d") 
| chart eval(round(count(PRODUCT)*2.5,2)) over TYPE by YMD useother=f limit=500
| addtotals col=true 2016-* labelfield=TYPE label="Product Type Totals" fieldname="Totals"
| foreach * [ eval &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;= if(isnum($&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;$), tostring($&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;$, "commas"), $&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;$) ]
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 05 Jul 2016 14:16:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237584#M70597</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2016-07-05T14:16:29Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237585#M70598</link>
      <description>&lt;P&gt;thanks woodcock it worked using manual search.&lt;BR /&gt;
one problem though, on my dashboard, i have a timerange ticker. the search we have (with dollar sign) does not load on a time range ticker dashboard. maybe the value of the time range ticker is being replaced on our search with dollar signs?&lt;/P&gt;

&lt;P&gt;the panel is showing "search is waiting for input..."&lt;/P&gt;</description>
      <pubDate>Thu, 07 Jul 2016 02:41:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237585#M70598</guid>
      <dc:creator>jonathan_yan5</dc:creator>
      <dc:date>2016-07-07T02:41:12Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237586#M70599</link>
      <description>&lt;P&gt;hi sundareshr thanks for your effort. however using your search does not show the "TYPE" column on the output.&lt;/P&gt;</description>
      <pubDate>Thu, 07 Jul 2016 02:47:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237586#M70599</guid>
      <dc:creator>jonathan_yan5</dc:creator>
      <dc:date>2016-07-07T02:47:46Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237587#M70600</link>
      <description>&lt;P&gt;Escape the dollar-signs by adding a second one next to each.&lt;/P&gt;</description>
      <pubDate>Thu, 07 Jul 2016 03:54:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237587#M70600</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2016-07-07T03:54:05Z</dc:date>
    </item>
    <item>
      <title>Re: how to place commas in the output of a chart with columns that varies depending on the search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237588#M70601</link>
      <description>&lt;P&gt;Wow! thanks a lot, it worked!&lt;/P&gt;</description>
      <pubDate>Thu, 07 Jul 2016 07:13:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-place-commas-in-the-output-of-a-chart-with-columns-that/m-p/237588#M70601</guid>
      <dc:creator>jonathan_yan5</dc:creator>
      <dc:date>2016-07-07T07:13:31Z</dc:date>
    </item>
  </channel>
</rss>

