<?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: question about labels in Splunk Dev</title>
    <link>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311251#M4203</link>
    <description>&lt;P&gt;You create the tag definitions outside of the dashboard and then have a list of tags and then use &lt;CODE&gt;tag=$tag_token$&lt;/CODE&gt; in your dashboard search strings.&lt;/P&gt;</description>
    <pubDate>Mon, 20 Feb 2017 23:08:12 GMT</pubDate>
    <dc:creator>woodcock</dc:creator>
    <dc:date>2017-02-20T23:08:12Z</dc:date>
    <item>
      <title>question about labels</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311247#M4199</link>
      <description>&lt;P&gt;Hi.&lt;/P&gt;

&lt;P&gt;with the code below, I am able to pull out data from our company's network and categorize them by region, as well as drilling down up to specific host. My only problem is, when I select for example 'APAC" in the first dropdown (token:region), the second dropdown with token $hostname$ displays the whole value of APAC as set in the condition,&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;      &amp;lt;set token="hostname"&amp;gt;toyosu* OR daikan* OR hongkong* OR singapore* OR sydney* OR taipei* OR seoul* OR tokyo* OR osaka* OR manila* OR beijing* OR tsuenwan* OR shenzhen* OR shanghai* OR jakarta* OR kualalumpur* OR mumbai* OR bangkok* OR wellington* OR melbourne* OR canberra*&amp;lt;/set&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;so, hte dropdown menu using token hostname will display "toyosu* OR ~ ...".&lt;/P&gt;

&lt;P&gt;Is there a way for me to set to display a custom label rather than the value of the whole token? like if i select "APAC" in the first dropdown, the second dropdown will display the token value , but will display as "ALL". &lt;/P&gt;

&lt;P&gt;index=nm "CFM defect" syslog_message!="CFM defect: none*" host=$host_name$&lt;BR /&gt;
  ＴＥＳＴ&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;input type="time" token="_time" searchWhenChanged="true"&amp;gt;
  &amp;lt;label&amp;gt;Time range&amp;lt;/label&amp;gt;
  &amp;lt;default&amp;gt;
    &amp;lt;earliest&amp;gt;-24h@h&amp;lt;/earliest&amp;gt;
    &amp;lt;latest&amp;gt;now&amp;lt;/latest&amp;gt;
  &amp;lt;/default&amp;gt;
&amp;lt;/input&amp;gt;
&amp;lt;input type="dropdown" token="region" searchWhenChanged="true"&amp;gt;

  &amp;lt;label&amp;gt;Select Region&amp;lt;/label&amp;gt;
  &amp;lt;choice value="*"&amp;gt;All&amp;lt;/choice&amp;gt;
  &amp;lt;choice value="toyosu* OR daikan* OR hongkong* OR singapore* OR sydney* OR taipei* OR seoul* OR tokyo* OR osaka* OR manila* OR beijing* OR tsuenwan* OR shenzhen* OR shanghai* OR jakarta* OR kualalumpur* OR mumbai* OR bangkok* OR wellington* OR melbourne* OR canberra*"&amp;gt;APAC&amp;lt;/choice&amp;gt;
  &amp;lt;choice value="metro* OR morristown* OR njr* OR njr1* OR ny* OR orange* OR secaucus* OR skillman* OR telx* OR weehawken* OR west* OR wilmington* OR ashburn* OR atlanta* OR boston* OR columbus* OR calgary* OR dcb* OR markham* OR miami* OR montreal* OR ottawa* OR southfield* OR toronto* OR vanc* OR washington* OR chicago* OR dallas* OR houston* OR kansas* OR losan* OR sanfran* OR seattle* OR bermuda* OR bogota* OR brasilia* OR buenos* OR caracas* OR lima* OR  mexico* OR monte* OR rio* OR santiago* OR saop*"&amp;gt;AMER&amp;lt;/choice&amp;gt;
  &amp;lt;choice value="abud* OR bahr* OR bucking* OR cairo* OR canning* OR capetown* OR citygate* OR dockland* OR dubai* OR dublin* OR guernsey* OR jersey-u* OR johannesburg* OR kuwait* OR lagos* OR qatar* OR riyadh* OR slough* OR telaviv* OR uae* OR zurich* OR amsterdam* OR athens* OR barcelona* OR brussels* OR budapest* OR copenhagen* OR dusseldorf* OR frankfurt* OR friesstrasse* OR geneva* OR hamburg* OR helsinki* OR istanbul* OR lisbon* OR luxembourg* OR madrid* OR milan* OR monaco* OR moscow* OR munich* OR oslo* OR paris* OR prague* OR rome* OR stockholm* OR stuttgart* OR vienna* OR warsaw* OR zurich*"&amp;gt;EMEA&amp;lt;/choice&amp;gt;
  &amp;lt;default&amp;gt;*&amp;lt;/default&amp;gt;

    &amp;lt;condition label="*"&amp;gt;
      &amp;lt;set token="hostname"&amp;gt;*&amp;lt;/set&amp;gt;
      &amp;lt;set token="hostname2"&amp;gt;*&amp;lt;/set&amp;gt;
    &amp;lt;/condition&amp;gt;
    &amp;lt;condition label="APAC"&amp;gt;
      &amp;lt;set token="hostname"&amp;gt;toyosu* OR daikan* OR hongkong* OR singapore* OR sydney* OR taipei* OR seoul* OR tokyo* OR osaka* OR manila* OR beijing* OR tsuenwan* OR shenzhen* OR shanghai* OR jakarta* OR kualalumpur* OR mumbai* OR bangkok* OR wellington* OR melbourne* OR canberra*&amp;lt;/set&amp;gt;
      &amp;lt;set token="hostname2"&amp;gt;toyosu* OR daikan* OR hongkong* OR singapore* OR sydney* OR taipei* OR seoul* OR tokyo* OR osaka* OR manila* OR beijing* OR tsuenwan* OR shenzhen* OR shanghai* OR jakarta* OR kualalumpur* OR mumbai* OR bangkok* OR wellington* OR melbourne* OR canberra*&amp;lt;/set&amp;gt;        
    &amp;lt;/condition&amp;gt;
    &amp;lt;condition label="EMEA"&amp;gt;
      &amp;lt;set token="hostname"&amp;gt;abud* OR bahr* OR bucking* OR cairo* OR canning* OR capetown* OR citygate* OR dockland* OR dubai* OR dublin* OR guernsey* OR jersey-u* OR johannesburg* OR kuwait* OR lagos* OR qatar* OR riyadh* OR slough* OR telaviv* OR uae* OR zurich* OR amsterdam* OR athens* OR barcelona* OR brussels* OR budapest* OR copenhagen* OR dusseldorf* OR frankfurt* OR friesstrasse* OR geneva* OR hamburg* OR helsinki* OR istanbul* OR lisbon* OR luxembourg* OR madrid* OR milan* OR monaco* OR moscow* OR munich* OR oslo* OR paris* OR prague* OR rome* OR stockholm* OR stuttgart* OR vienna* OR warsaw* OR zurich*&amp;lt;/set&amp;gt;
      &amp;lt;set token="hostname2"&amp;gt;abud* OR bahr* OR bucking* OR cairo* OR canning* OR capetown* OR citygate* OR dockland* OR dubai* OR dublin* OR guernsey* OR jersey-u* OR johannesburg* OR kuwait* OR lagos* OR qatar* OR riyadh* OR slough* OR telaviv* OR uae* OR zurich* OR amsterdam* OR athens* OR barcelona* OR brussels* OR budapest* OR copenhagen* OR dusseldorf* OR frankfurt* OR friesstrasse* OR geneva* OR hamburg* OR helsinki* OR istanbul* OR lisbon* OR luxembourg* OR madrid* OR milan* OR monaco* OR moscow* OR munich* OR oslo* OR paris* OR prague* OR rome* OR stockholm* OR stuttgart* OR vienna* OR warsaw* OR zurich*&amp;lt;/set&amp;gt;        
    &amp;lt;/condition&amp;gt;
    &amp;lt;condition label="AMER"&amp;gt;
    &amp;lt;set token="hostname"&amp;gt;metro* OR morristown* OR njr* OR njr1* OR ny* OR orange* OR secaucus* OR skillman* OR telx* OR weehawken* OR west* OR wilmington* OR ashburn* OR atlanta* OR boston* OR columbus* OR calgary* OR dcb* OR markham* OR miami* OR montreal* OR ottawa* OR southfield* OR toronto* OR vanc* OR washington* OR chicago* OR dallas* OR houston* OR kansas* OR losan* OR sanfran* OR seattle* OR bermuda* OR bogota* OR brasilia* OR buenos* OR caracas* OR lima* OR  mexico* OR monte* OR rio* OR santiago* OR saop*&amp;lt;/set&amp;gt; 
    &amp;lt;set token="hostname2"&amp;gt;metro* OR morristown* OR njr* OR njr1* OR ny* OR orange* OR secaucus* OR skillman* OR telx* OR weehawken* OR west* OR wilmington* OR ashburn* OR atlanta* OR boston* OR columbus* OR calgary* OR dcb* OR markham* OR miami* OR montreal* OR ottawa* OR southfield* OR toronto* OR vanc* OR washington* OR chicago* OR dallas* OR houston* OR kansas* OR losan* OR sanfran* OR seattle* OR bermuda* OR bogota* OR brasilia* OR buenos* OR caracas* OR lima* OR  mexico* OR monte* OR rio* OR santiago* OR saop*&amp;lt;/set&amp;gt;
    &amp;lt;/condition&amp;gt;

&amp;lt;/input&amp;gt;
&amp;lt;input type="dropdown" token="hostname" searchWhenChanged="true"&amp;gt;
  &amp;lt;label&amp;gt;Select Host for CFM&amp;lt;/label&amp;gt;
  &amp;lt;search&amp;gt;
    &amp;lt;query&amp;gt;index=nm "CFM defect" syslog_message!="CFM defect: none*" host=$region$ | top host&amp;lt;/query&amp;gt;
    &amp;lt;earliest&amp;gt;$_time.earliest$&amp;lt;/earliest&amp;gt;
    &amp;lt;latest&amp;gt;$_time.latest$&amp;lt;/latest&amp;gt;
  &amp;lt;/search&amp;gt;
  &amp;lt;fieldForlabel&amp;gt;host&amp;lt;/fieldForlabel&amp;gt;
  &amp;lt;fieldForValue&amp;gt;host&amp;lt;/fieldForValue&amp;gt;
  &amp;lt;default&amp;gt;$region$&amp;lt;/default&amp;gt;
  &amp;lt;/input&amp;gt;

&amp;lt;input type="dropdown" token="hostname2" searchWhenChanged="true"&amp;gt;
&amp;lt;label&amp;gt;Select Host for OSPF&amp;lt;/label&amp;gt;
&amp;lt;search&amp;gt;
      &amp;lt;query&amp;gt;index=nm "RPD_OSPF_NBR*" syslog_message!="*ExStart due to*" host=$region$| top host &amp;lt;/query&amp;gt;
      &amp;lt;earliest&amp;gt;$_time.earliest$&amp;lt;/earliest&amp;gt;
      &amp;lt;latest&amp;gt;$_time.latest$&amp;lt;/latest&amp;gt;
 &amp;lt;/search&amp;gt;
   &amp;lt;fieldForlabel&amp;gt;host&amp;lt;/fieldForlabel&amp;gt;
  &amp;lt;fieldForValue&amp;gt;host&amp;lt;/fieldForValue&amp;gt;
  &amp;lt;default&amp;gt;$region$&amp;lt;/default&amp;gt;
&amp;lt;/input&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 29 Sep 2020 12:55:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311247#M4199</guid>
      <dc:creator>ringbbg</dc:creator>
      <dc:date>2020-09-29T12:55:56Z</dc:date>
    </item>
    <item>
      <title>Re: question about labels</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311248#M4200</link>
      <description>&lt;P&gt;Why not use tags?&lt;/P&gt;

&lt;P&gt;We do something similar in our environment:&lt;BR /&gt;
We assign tags based on the hostname parts of of servers, so PROD-eu1-webserver-01 gets broken into&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;tag=PROD
tag=eu1
tag=webserver
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;We now build our panels with three token drop downs for Environment, Location, Service, each with an ALL (*) option too.&lt;BR /&gt;
You can either specify your tags in the form (if they don't change often) or load them from a populating search. &lt;BR /&gt;
If you decide on the latter consider building a scheduled search to populate a lookup table with your various tag names, and then load the lookup when your form loads.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Feb 2017 07:54:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311248#M4200</guid>
      <dc:creator>nickhills</dc:creator>
      <dc:date>2017-02-20T07:54:05Z</dc:date>
    </item>
    <item>
      <title>Re: question about labels</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311249#M4201</link>
      <description>&lt;P&gt;Yes, this screams for &lt;CODE&gt;tags&lt;/CODE&gt; ( tag=APAC, etc.)&lt;/P&gt;</description>
      <pubDate>Mon, 20 Feb 2017 16:17:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311249#M4201</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2017-02-20T16:17:54Z</dc:date>
    </item>
    <item>
      <title>Re: question about labels</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311250#M4202</link>
      <description>&lt;P&gt;Thanks for the reply. if i want to specify the tags in the form, what would the syntax be? I keep getting error if i use  . &lt;/P&gt;</description>
      <pubDate>Mon, 20 Feb 2017 22:59:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311250#M4202</guid>
      <dc:creator>ringbbg</dc:creator>
      <dc:date>2017-02-20T22:59:50Z</dc:date>
    </item>
    <item>
      <title>Re: question about labels</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311251#M4203</link>
      <description>&lt;P&gt;You create the tag definitions outside of the dashboard and then have a list of tags and then use &lt;CODE&gt;tag=$tag_token$&lt;/CODE&gt; in your dashboard search strings.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Feb 2017 23:08:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/question-about-labels/m-p/311251#M4203</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2017-02-20T23:08:12Z</dc:date>
    </item>
  </channel>
</rss>

