<?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 timechart linechart to display in and out per device in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/timechart-linechart-to-display-in-and-out-per-device/m-p/494837#M137911</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I have a query which gives me in_usage and out_usage for a device per metric&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;bla bla ...| table Device metric_name "in_usage%" "out_usage%"  
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Now i want to display the top20 in_usage in one line in the line chart graph and out_usage in another line in the same graph by Device and metric_name.&lt;/P&gt;

&lt;P&gt;How to do that am little confused.&lt;/P&gt;

&lt;P&gt;I tried using below at the end but i dont want to explicitly sort it by out it should be sorted by both in/out&lt;/P&gt;

&lt;P&gt;| stats values("in_usage%") as IN_usage values("out_usage%") as OUT_usage by Device metric_name | sort - OUT_usage |head 20&lt;/P&gt;

&lt;P&gt;Please help&lt;/P&gt;</description>
    <pubDate>Wed, 30 Sep 2020 05:22:41 GMT</pubDate>
    <dc:creator>surekhasplunk</dc:creator>
    <dc:date>2020-09-30T05:22:41Z</dc:date>
    <item>
      <title>timechart linechart to display in and out per device</title>
      <link>https://community.splunk.com/t5/Splunk-Search/timechart-linechart-to-display-in-and-out-per-device/m-p/494837#M137911</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I have a query which gives me in_usage and out_usage for a device per metric&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;bla bla ...| table Device metric_name "in_usage%" "out_usage%"  
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Now i want to display the top20 in_usage in one line in the line chart graph and out_usage in another line in the same graph by Device and metric_name.&lt;/P&gt;

&lt;P&gt;How to do that am little confused.&lt;/P&gt;

&lt;P&gt;I tried using below at the end but i dont want to explicitly sort it by out it should be sorted by both in/out&lt;/P&gt;

&lt;P&gt;| stats values("in_usage%") as IN_usage values("out_usage%") as OUT_usage by Device metric_name | sort - OUT_usage |head 20&lt;/P&gt;

&lt;P&gt;Please help&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 05:22:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/timechart-linechart-to-display-in-and-out-per-device/m-p/494837#M137911</guid>
      <dc:creator>surekhasplunk</dc:creator>
      <dc:date>2020-09-30T05:22:41Z</dc:date>
    </item>
    <item>
      <title>Re: timechart linechart to display in and out per device</title>
      <link>https://community.splunk.com/t5/Splunk-Search/timechart-linechart-to-display-in-and-out-per-device/m-p/494838#M137912</link>
      <description>&lt;P&gt;The &lt;CODE&gt;sort&lt;/CODE&gt; command can sort on more than one field.  For example, &lt;CODE&gt;sort 0 -OUT_usage, IN_usage&lt;/CODE&gt;.&lt;/P&gt;</description>
      <pubDate>Thu, 07 May 2020 12:55:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/timechart-linechart-to-display-in-and-out-per-device/m-p/494838#M137912</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2020-05-07T12:55:29Z</dc:date>
    </item>
    <item>
      <title>Re: timechart linechart to display in and out per device</title>
      <link>https://community.splunk.com/t5/Splunk-Search/timechart-linechart-to-display-in-and-out-per-device/m-p/494839#M137913</link>
      <description>&lt;P&gt;I tried to sort as you suggested but not working for my case.&lt;BR /&gt;&lt;BR /&gt;
if i write like this sort 0 -OUT_usage, IN_usage  ----&amp;gt; OUT_usage gets sorted in decending&lt;BR /&gt;
if i write like this sort 0 -IN_usage, OUT_usage   ----&amp;gt; IN_usage gets sorted in decending. &lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 05:20:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/timechart-linechart-to-display-in-and-out-per-device/m-p/494839#M137913</guid>
      <dc:creator>surekhasplunk</dc:creator>
      <dc:date>2020-09-30T05:20:09Z</dc:date>
    </item>
    <item>
      <title>Re: timechart linechart to display in and out per device</title>
      <link>https://community.splunk.com/t5/Splunk-Search/timechart-linechart-to-display-in-and-out-per-device/m-p/494840#M137914</link>
      <description>&lt;P&gt;That is the way &lt;CODE&gt;sort&lt;/CODE&gt; works.  It's rather like sorting in Excel.  Sort by one column and when there are duplicates in that column, sort by the other column.&lt;BR /&gt;
How exactly do you want your data sorted?  Examples?&lt;/P&gt;</description>
      <pubDate>Fri, 08 May 2020 12:42:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/timechart-linechart-to-display-in-and-out-per-device/m-p/494840#M137914</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2020-05-08T12:42:54Z</dc:date>
    </item>
  </channel>
</rss>

