<?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 rename label in splunk legend that not effected the lookup name? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382756#M111829</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I take it back got it to work now by using your strategy above code.&lt;BR /&gt;
Once last thing, Base on my work.jpg, I would like to show or display all Legend Label in splunk bar chart dashboard, as of now only show up to 9 items on the legend. Is there away to display all legend label?&lt;/P&gt;</description>
    <pubDate>Wed, 11 Dec 2019 17:07:05 GMT</pubDate>
    <dc:creator>matoulas</dc:creator>
    <dc:date>2019-12-11T17:07:05Z</dc:date>
    <item>
      <title>How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382753#M111826</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I would like to display each plugname on the legend instead of plug1, plug2, plug3 and so on using timechart.&lt;BR /&gt;
I was able to display plug1, plug2, plug3 as a lable name and so on, on the chart legend, but couldn't get the plugname for each plug to display on the legend.&lt;/P&gt;

&lt;P&gt;How to rename or show  a label in splunk legend to show the dynamic plugname when performing a search.&lt;BR /&gt;
Please looking forward to your help to resolve this problem.&lt;/P&gt;

&lt;P&gt;Below is the JSON code that send to Splunk:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;{
    "timestamp": "2019-06-21T21:50:13+00:00",
    "siteid": "LABRACK1",
    "assettag": "CPM-1600-1-ECAM-LAB",
    "powerunit": "1",
    "outletmetering": "1",
    "ats": "1",
    "branchcount": "2",
    "plugcount": "16",
    "powerfactor": "100",
    "powereff": "100",
    "powerdatacount": "1",
    "powerdata": [{
        "timestamp": "2019-06-21T21:50:13+00:00",
        "plug1": [{
            "voltage": "114.00",
            "current": "2.00",
            "branch": "1",
                        "plugname": "Outlet_A1"
        }],
        "plug2": [{
            "voltage": "114.00",
            "current": "5.00",
            "branch": "1",
                        "plugname": "Outlet_A2"
        }],
        "plug3": [{
            "voltage": "114.00",
            "current": "3.00",
            "branch": "1",
                        "plugname": "Cisco-ASA5510"
        }],
        "plug4": [{
            "voltage": "114.00",
            "current": "1.00",
            "branch": "1",
                        "plugname": "Cisco-SW3560"
        }],
        "plug5": [{
            "voltage": "114.00",
            "current": "2.00",
            "branch": "1",
                        "plugname": "Cisco-SW3760"
        }],
        "plug6": [{
            "voltage": "114.00",
            "current": "5.00",
            "branch": "1",
                        "plugname": "UPS"
        }],
        "plug7": [{
            "voltage": "114.00",
            "current": "3.00",
            "branch": "1",
                        "plugname": "Outlet_A7"
        }],
        "plug8": [{
            "voltage": "114.00",
            "current": "1.00",
            "branch": "1",
                        "plugname": "Outlet_A8"
        }],
        "plug9": [{
            "voltage": "119.00",
            "current": "2.00",
            "branch": "2",
                        "plugname": "F5"
        }],
        "plug10": [{
            "voltage": "119.00",
            "current": "7.00",
            "branch": "2",
                        "plugname": "Camera"
        }],
        "plug11": [{
            "voltage": "119.00",
            "current": "5.00",
            "branch": "2",
                        "plugname": "TV"
        }],
        "plug12": [{
            "voltage": "119.00",
            "current": "1.00",
            "branch": "2",
                        "plugname": "Meraki"
        }],
        "plug13": [{
            "voltage": "119.00",
            "current": "4.00",
            "branch": "2",
                        "plugname": "Outlet_13"
        }],
        "plug14": [{
            "voltage": "119.00",
            "current": "5.00",
            "branch": "2",
                        "plugname": "Outlet_A14"
        }],
        "plug15": [{
            "voltage": "119.00",
            "current": "3.00",
            "branch": "2",
                        "plugname": "PC"
        }],
        "plug16": [{
            "voltage": "119.00",
            "current": "1.00",
            "branch": "2",
                        "plugname": "Outlet_A16"
        }]
    }]
}
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 09 Jul 2019 17:16:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382753#M111826</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-07-09T17:16:35Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382754#M111827</link>
      <description>&lt;P&gt;How about this strategy:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| rex mode=sed "s/plug(\d)/plug/g" 
| spath output=pname path=powerdata{}.plug{}.plugname
| spath
| timechart max(powerdata{}.plug{}.current) as max_current,  max(powerdata{}.plug{}.voltage) as max_voltage by powerdata{}.plug{}.plugname
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 09 Jul 2019 20:41:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382754#M111827</guid>
      <dc:creator>tiagofbmm</dc:creator>
      <dc:date>2019-07-09T20:41:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382755#M111828</link>
      <description>&lt;P&gt;If I performed my search like this is working&lt;/P&gt;

&lt;P&gt;index="main" &lt;BR /&gt;
 | rex mode=sed "s/plug(\d)/plug/g" &lt;BR /&gt;
 | spath output=pname path=powerdata{}.plug{}.plugname&lt;BR /&gt;
 | spath&lt;BR /&gt;
 | timechart max(powerdata{}.plug{}.current) as max_current by powerdata{}.plug{}.plugname&lt;/P&gt;

&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/7304iEEEC322A86825B0D/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;but I would like to filter my search base on dropdown selection with the token as siteid=$siteid$ and location=$location$ &lt;BR /&gt;
if I want to perform my search as the below. It said no result found in dasboard.&lt;/P&gt;

&lt;P&gt;| search siteid=$siteid$ location=$location$ &lt;BR /&gt;
| rex mode=sed "s/plug(\d)/plug/g" &lt;BR /&gt;
| spath output=pname path=powerdata{}.plug{}.plugname&lt;BR /&gt;
| spath&lt;BR /&gt;
| timechart max(powerdata{}.plug{}.current) as max_current by powerdata{}.plug{}.plugname&lt;/P&gt;

&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/7305iF1A2E77852C3F02A/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Dec 2019 07:05:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382755#M111828</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-12-11T07:05:43Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382756#M111829</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I take it back got it to work now by using your strategy above code.&lt;BR /&gt;
Once last thing, Base on my work.jpg, I would like to show or display all Legend Label in splunk bar chart dashboard, as of now only show up to 9 items on the legend. Is there away to display all legend label?&lt;/P&gt;</description>
      <pubDate>Wed, 11 Dec 2019 17:07:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382756#M111829</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-12-11T17:07:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382757#M111830</link>
      <description>&lt;P&gt;Another thing that I found out when using the above code my result for all plug current and voltage is not correct.&lt;/P&gt;</description>
      <pubDate>Wed, 11 Dec 2019 20:28:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382757#M111830</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-12-11T20:28:42Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382758#M111831</link>
      <description>&lt;P&gt;Updated I got it to display all the plug now from at lest 1 digit or more&lt;/P&gt;

&lt;P&gt;| rex mode=sed "s/plug(\d+)/plug/g"&lt;/P&gt;

&lt;P&gt;By follow the splunk doc regular expression&lt;BR /&gt;
&lt;A href="https://docs.splunk.com/Documentation/Splunk/8.0.0/Knowledge/AboutSplunkregularexpressions"&gt;https://docs.splunk.com/Documentation/Splunk/8.0.0/Knowledge/AboutSplunkregularexpressions&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Dec 2019 23:14:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382758#M111831</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-12-11T23:14:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382759#M111832</link>
      <description>&lt;P&gt;Need help when using your suggestion above code is working great but why do I get a result for all the  plug current from Outlet_A1 - Outlet_B8 are showing the same result like 1.97 and so on. It should show the difference for each Outlet-A1 - Outlet_B8 base on the plug current. See screenshot for details.&lt;/P&gt;

&lt;P&gt;&lt;IMG src="https://community.splunk.com/storage/temp/276734-incorrect-result.jpg" alt="alt text" /&gt; &lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 03:19:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382759#M111832</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2020-09-30T03:19:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382760#M111833</link>
      <description>&lt;P&gt;Need your help see below &lt;/P&gt;</description>
      <pubDate>Thu, 12 Dec 2019 19:07:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382760#M111833</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-12-12T19:07:14Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382761#M111834</link>
      <description>&lt;P&gt;Wow, that was &lt;EM&gt;FUN&lt;/EM&gt;!  Try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| makeresults 
|  eval _raw="{
    \"timestamp\": \"2019-06-21T21:50:13+00:00\",
    \"siteid\": \"LABRACK1\",
    \"assettag\": \"CPM-1600-1-ECAM-LAB\",
    \"powerunit\": \"1\",
    \"outletmetering\": \"1\",
    \"ats\": \"1\",
    \"branchcount\": \"2\",
    \"plugcount\": \"16\",
    \"powerfactor\": \"100\",
    \"powereff\": \"100\",
    \"powerdatacount\": \"1\",
    \"powerdata\": [{
        \"timestamp\": \"2019-06-21T21:50:13+00:00\",
        \"plug1\": [{
            \"voltage\": \"114.00\",
            \"current\": \"2.00\",
            \"branch\": \"1\",
                        \"plugname\": \"Outlet_A1\"
        }],
        \"plug2\": [{
            \"voltage\": \"114.00\",
            \"current\": \"5.00\",
            \"branch\": \"1\",
                        \"plugname\": \"Outlet_A2\"
        }],
        \"plug3\": [{
            \"voltage\": \"114.00\",
            \"current\": \"3.00\",
            \"branch\": \"1\",
                        \"plugname\": \"Cisco-ASA5510\"
        }],
        \"plug4\": [{
            \"voltage\": \"114.00\",
            \"current\": \"1.00\",
            \"branch\": \"1\",
                        \"plugname\": \"Cisco-SW3560\"
        }],
        \"plug5\": [{
            \"voltage\": \"114.00\",
            \"current\": \"2.00\",
            \"branch\": \"1\",
                        \"plugname\": \"Cisco-SW3760\"
        }],
        \"plug6\": [{
            \"voltage\": \"114.00\",
            \"current\": \"5.00\",
            \"branch\": \"1\",
                        \"plugname\": \"UPS\"
        }],
        \"plug7\": [{
            \"voltage\": \"114.00\",
            \"current\": \"3.00\",
            \"branch\": \"1\",
                        \"plugname\": \"Outlet_A7\"
        }],
        \"plug8\": [{
            \"voltage\": \"114.00\",
            \"current\": \"1.00\",
            \"branch\": \"1\",
                        \"plugname\": \"Outlet_A8\"
        }],
        \"plug9\": [{
            \"voltage\": \"119.00\",
            \"current\": \"2.00\",
            \"branch\": \"2\",
                        \"plugname\": \"F5\"
        }],
        \"plug10\": [{
            \"voltage\": \"119.00\",
            \"current\": \"7.00\",
            \"branch\": \"2\",
                        \"plugname\": \"Camera\"
        }],
        \"plug11\": [{
            \"voltage\": \"119.00\",
            \"current\": \"5.00\",
            \"branch\": \"2\",
                        \"plugname\": \"TV\"
        }],
        \"plug12\": [{
            \"voltage\": \"119.00\",
            \"current\": \"1.00\",
            \"branch\": \"2\",
                        \"plugname\": \"Meraki\"
        }],
        \"plug13\": [{
            \"voltage\": \"119.00\",
            \"current\": \"4.00\",
            \"branch\": \"2\",
                        \"plugname\": \"Outlet_13\"
        }],
        \"plug14\": [{
            \"voltage\": \"119.00\",
            \"current\": \"5.00\",
            \"branch\": \"2\",
                        \"plugname\": \"Outlet_A14\"
        }],
        \"plug15\": [{
            \"voltage\": \"119.00\",
            \"current\": \"3.00\",
            \"branch\": \"2\",
                        \"plugname\": \"PC\"
        }],
        \"plug16\": [{
            \"voltage\": \"119.00\",
            \"current\": \"1.00\",
            \"branch\": \"2\",
                        \"plugname\": \"Outlet_A16\"
        }]
    }]
}"

| rename COMMENT AS "Everything above generates sample event data; everything below is your solution."

| spath
| fields - _raw
| foreach powerdata{}.plug*{}.* [ eval eachplug&amp;lt;&amp;lt;MATCHSEG1&amp;gt;&amp;gt; = mvappend(eachplug&amp;lt;&amp;lt;MATCHSEG1&amp;gt;&amp;gt;, "&amp;lt;&amp;lt;MATCHSEG2&amp;gt;&amp;gt;=" . '&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;') |  fields - &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; ]
| foreach eachplug* [ nomv &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; |  eval allplugs = mvappend(allplugs, "plug=&amp;lt;&amp;lt;MATCHSTR&amp;gt;&amp;gt;, " . &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;) |  fields - &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; ]
| mvexpand allplugs
| rename allplugs AS _raw
| kv
| timechart limit=0 max(current) AS max_current BY plugname
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 12 Dec 2019 23:55:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382761#M111834</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2019-12-12T23:55:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382762#M111835</link>
      <description>&lt;P&gt;This approach rearranges each single event into multilpe events, one for each plugname.  From there you can do anything easily.&lt;/P&gt;</description>
      <pubDate>Thu, 12 Dec 2019 23:59:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382762#M111835</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2019-12-12T23:59:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382763#M111836</link>
      <description>&lt;P&gt;It work!!! &lt;BR /&gt;
Thank you so much!&lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2019 00:13:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382763#M111836</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-12-13T00:13:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382764#M111837</link>
      <description>&lt;PRE&gt;&lt;CODE&gt;| makeresults 
| eval _raw="{
\"timestamp\": \"2019-06-21T21:50:13+00:00\",
\"siteid\": \"LABRACK1\",
\"assettag\": \"CPM-1600-1-ECAM-LAB\",
\"powerunit\": \"1\",
\"outletmetering\": \"1\",
\"ats\": \"1\",
\"branchcount\": \"2\",
\"plugcount\": \"16\",
\"powerfactor\": \"100\",
\"powereff\": \"100\",
\"powerdatacount\": \"1\",
\"powerdata\": [{
\"timestamp\": \"2019-06-21T21:50:13+00:00\",
\"plug1\": [{
\"voltage\": \"114.00\",
\"current\": \"2.00\",
\"branch\": \"1\",
\"plugname\": \"Outlet_A1\"
}],
\"plug2\": [{
\"voltage\": \"114.00\",
\"current\": \"5.00\",
\"branch\": \"1\",
\"plugname\": \"Outlet_A2\"
}],
\"plug3\": [{
\"voltage\": \"114.00\",
\"current\": \"3.00\",
\"branch\": \"1\",
\"plugname\": \"Cisco-ASA5510\"
}],
\"plug4\": [{
\"voltage\": \"114.00\",
\"current\": \"1.00\",
\"branch\": \"1\",
\"plugname\": \"Cisco-SW3560\"
}],
\"plug5\": [{
\"voltage\": \"114.00\",
\"current\": \"2.00\",
\"branch\": \"1\",
\"plugname\": \"Cisco-SW3760\"
}],
\"plug6\": [{
\"voltage\": \"114.00\",
\"current\": \"5.00\",
\"branch\": \"1\",
\"plugname\": \"UPS\"
}],
\"plug7\": [{
\"voltage\": \"114.00\",
\"current\": \"3.00\",
\"branch\": \"1\",
\"plugname\": \"Outlet_A7\"
}],
\"plug8\": [{
\"voltage\": \"114.00\",
\"current\": \"1.00\",
\"branch\": \"1\",
\"plugname\": \"Outlet_A8\"
}],
\"plug9\": [{
\"voltage\": \"119.00\",
\"current\": \"2.00\",
\"branch\": \"2\",
\"plugname\": \"F5\"
}],
\"plug10\": [{
\"voltage\": \"119.00\",
\"current\": \"7.00\",
\"branch\": \"2\",
\"plugname\": \"Camera\"
}],
\"plug11\": [{
\"voltage\": \"119.00\",
\"current\": \"5.00\",
\"branch\": \"2\",
\"plugname\": \"TV\"
}],
\"plug12\": [{
\"voltage\": \"119.00\",
\"current\": \"1.00\",
\"branch\": \"2\",
\"plugname\": \"Meraki\"
}],
\"plug13\": [{
\"voltage\": \"119.00\",
\"current\": \"4.00\",
\"branch\": \"2\",
\"plugname\": \"Outlet_13\"
}],
\"plug14\": [{
\"voltage\": \"119.00\",
\"current\": \"5.00\",
\"branch\": \"2\",
\"plugname\": \"Outlet_A14\"
}],
\"plug15\": [{
\"voltage\": \"119.00\",
\"current\": \"3.00\",
\"branch\": \"2\",
\"plugname\": \"PC\"
}],
\"plug16\": [{
\"voltage\": \"119.00\",
\"current\": \"1.00\",
\"branch\": \"2\",
\"plugname\": \"Outlet_A16\"
}]
}]
}"
| spath
| fields - _raw
| untable _time category status
| rex field=category "powerdata\{\}\.(?&amp;lt;plug&amp;gt;\w+)\{\}\.(?&amp;lt;cat&amp;gt;\w+)"
| eval tmp=mvzip(cat,status,"=")
| rename tmp as _raw
| kv
| fields - _raw category status cat
| stats values(_time) as _time values(*) as * by plug
| sort 0 branch plug
`comment("table create")`
| table _time plugname current
| xyseries _time plugname current
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;It was also beautiful here.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| spath 
| fields - _raw 
| untable _time category status 
| rex field=category "powerdata\{\}\.(?&amp;lt;plug&amp;gt;\w+)\{\}\.(?&amp;lt;cat&amp;gt;\w+)" 
| chart limit=0 values(status) values(_time) as t over plug by cat 
| table "t: plugname" values(status)* 
| rename "t: plugname" as _time, "values(status): *" as * 
| sort 0 branch 
`comment("table create")` 
| table _time plugname current 
| xyseries _time plugname current
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This is also, too.&lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2019 11:22:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382764#M111837</guid>
      <dc:creator>to4kawa</dc:creator>
      <dc:date>2019-12-13T11:22:53Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382765#M111838</link>
      <description>&lt;P&gt;I got the warning message on my bar chart said Field 'allplugs' does not exist in the data. Only when I select individual siteid and location from my drop down.&lt;/P&gt;

&lt;P&gt;when using this search string on my dashboard&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| search siteid=$siteid$ location=$location$
| foreach powerdata{}.plug*{}.* [ eval eachplug&amp;lt;&amp;lt;MATCHSEG1&amp;gt;&amp;gt; = mvappend(eachplug&amp;lt;&amp;lt;MATCHSEG1&amp;gt;&amp;gt;, "&amp;lt;&amp;lt;MATCHSEG2&amp;gt;&amp;gt;=" . '&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;') |  fields - &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; ]
| foreach eachplug* [ nomv &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; |  eval allplugs = mvappend(allplugs, "plug=&amp;lt;&amp;lt;MATCHSTR&amp;gt;&amp;gt;, " . &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;) |  fields - &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; ]
| mvexpand allplugs
| rename allplugs AS _raw
| kv
| timechart limit=0 max(current) AS max_current BY plugname
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;But when I select ALL from  my drop down the warning working great.  &lt;/P&gt;

&lt;P&gt;How to bypass the the 'allplugs' when not selected ALL?&lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2019 16:31:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382765#M111838</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-12-13T16:31:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382766#M111839</link>
      <description>&lt;P&gt;Never mind the warning just went away now.  Thanks for all your help.&lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2019 16:40:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382766#M111839</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-12-13T16:40:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382767#M111840</link>
      <description>&lt;P&gt;Must be a problem with your dashboard tokens.&lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2019 16:52:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382767#M111840</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2019-12-13T16:52:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382768#M111841</link>
      <description>&lt;P&gt;Hi woodcock,&lt;/P&gt;

&lt;P&gt;In addition, I would like to be able to click on the legend label for drill down to see individual activity current occur per plug name.&lt;/P&gt;

&lt;P&gt;Here is my search string&lt;/P&gt;

&lt;P&gt;| search siteid=$siteid$ location=$location$&lt;BR /&gt;
| foreach powerdata{}.plug*{}.* [ eval eachplug&amp;lt;&amp;gt; = mvappend(eachplug&amp;lt;&amp;gt;, "&amp;lt;&amp;gt;=" . '&amp;lt;&amp;gt;') |  fields - &amp;lt;&amp;gt; ]&lt;BR /&gt;
| foreach eachplug* [ nomv &amp;lt;&amp;gt; |  eval allplugs = mvappend(allplugs, "plug=&amp;lt;&amp;gt;, " . &amp;lt;&amp;gt;) |  fields - &amp;lt;&amp;gt; ]&lt;BR /&gt;
| mvexpand allplugs&lt;BR /&gt;
| rename allplugs AS _raw&lt;BR /&gt;
| kv&lt;BR /&gt;
| timechart limit=0 max(voltage) AS max_voltage BY plugname&lt;/P&gt;

&lt;P&gt;The bar chart work great as expected, but need to be able to click on a single legend for the drill down on the bar chart.  I don't know how to do it.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 03:22:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382768#M111841</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2020-09-30T03:22:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382769#M111842</link>
      <description>&lt;P&gt;Now the search query is working base on &lt;/P&gt;

&lt;P&gt;Search query:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;siteid=* location=*
| foreach powerdata{}.plug*{}.* [ eval eachplug&amp;lt;&amp;lt;MATCHSEG1&amp;gt;&amp;gt; = mvappend(eachplug&amp;lt;&amp;lt;MATCHSEG1&amp;gt;&amp;gt;, "&amp;lt;&amp;lt;MATCHSEG2&amp;gt;&amp;gt;=" . '&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;') |  fields - &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; ]
| foreach eachplug* [ nomv &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; |  eval allplugs = mvappend(allplugs, "plug=&amp;lt;&amp;lt;MATCHSTR&amp;gt;&amp;gt;, " . &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;) |  fields - &amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt; ]
| mvexpand allplugs
| rename allplugs AS _raw
| kv
| timechart limit=0 max(current) AS max_current BY plugname
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/7308i1E9976408F70253E/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;In addition, next step I would like to be able to click on individual plug name on the bar chart or from  the legend label for the drill down details. As of now when I click it. It said no result found. Please I really need help and thank you in advance.&lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2019 21:08:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382769#M111842</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-12-13T21:08:12Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382770#M111843</link>
      <description>&lt;P&gt;Start a new question.&lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2019 21:38:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382770#M111843</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2019-12-13T21:38:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to rename label in splunk legend that not effected the lookup name?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382771#M111844</link>
      <description>&lt;P&gt;Here is my new question. Thanks&lt;/P&gt;

&lt;P&gt;&lt;A href="https://answers.splunk.com/answers/789135/how-do-i-make-a-drill-down-details-from-when-click.html?minQuestionBodyLength=80"&gt;https://answers.splunk.com/answers/789135/how-do-i-make-a-drill-down-details-from-when-click.html?minQuestionBodyLength=80&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Dec 2019 22:07:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-rename-label-in-splunk-legend-that-not-effected-the/m-p/382771#M111844</guid>
      <dc:creator>matoulas</dc:creator>
      <dc:date>2019-12-13T22:07:34Z</dc:date>
    </item>
  </channel>
</rss>

