Splunk Search

how to create hyperlink for a plain text that directs to search query on splunk dashboard

REACHGPRAVEEN
Explorer

Hi ,

Please help on this @niketn

the below 2 rows as single panel

search by employeeid(hyperlink)

search by app(hyperlink)

once clicked on above  hyperlinks it should open new search with search query

index = x  | search employeeid =123

index= x | search app = abc

 

Thanks in advance

Labels (1)
0 Karma
1 Solution

renjith_nair
Legend

are you looking for something similar?

<dashboard>
  <label>Hyperlinks</label>
  <row>
    <panel>
      <single>
        <search>
          <query>|makeresults|eval message="search by employeeid"</query>
          <earliest>-15m</earliest>
          <latest>now</latest>
        </search>
        <option name="drilldown">all</option>
        <option name="refresh.display">progressbar</option>
        <drilldown>
          <link target="_blank">search?q=index%20%3D%20x%20%20%7C%20search%20employeeid%20%3D123&amp;earliest=-15m&amp;latest=now</link>
        </drilldown>
      </single>
      <single>
        <search>
          <query>|makeresults|eval message="search by app"</query>
          <earliest>-15m</earliest>
          <latest>now</latest>
        </search>
        <option name="drilldown">all</option>
        <option name="refresh.display">progressbar</option>
        <drilldown>
          <link target="_blank">search?q=index%3D%20x%20%7C%20search%20app%20%3D%20abc&amp;earliest=-15m&amp;latest=now</link>
        </drilldown>
      </single>
    </panel>
  </row>
</dashboard>
Happy Splunking!

View solution in original post

0 Karma

renjith_nair
Legend

are you looking for something similar?

<dashboard>
  <label>Hyperlinks</label>
  <row>
    <panel>
      <single>
        <search>
          <query>|makeresults|eval message="search by employeeid"</query>
          <earliest>-15m</earliest>
          <latest>now</latest>
        </search>
        <option name="drilldown">all</option>
        <option name="refresh.display">progressbar</option>
        <drilldown>
          <link target="_blank">search?q=index%20%3D%20x%20%20%7C%20search%20employeeid%20%3D123&amp;earliest=-15m&amp;latest=now</link>
        </drilldown>
      </single>
      <single>
        <search>
          <query>|makeresults|eval message="search by app"</query>
          <earliest>-15m</earliest>
          <latest>now</latest>
        </search>
        <option name="drilldown">all</option>
        <option name="refresh.display">progressbar</option>
        <drilldown>
          <link target="_blank">search?q=index%3D%20x%20%7C%20search%20app%20%3D%20abc&amp;earliest=-15m&amp;latest=now</link>
        </drilldown>
      </single>
    </panel>
  </row>
</dashboard>
Happy Splunking!
0 Karma

REACHGPRAVEEN
Explorer

Hi renjith_nair,

 

the link opened breaks in sometime . is it with time picker? May i know how to decrease the font of single value displayed please.. Thanks in advance

0 Karma

REACHGPRAVEEN
Explorer

ThankYou so much @renjith_nair  I appreciate your time and response

0 Karma
Get Updates on the Splunk Community!

Adoption of RUM and APM at Splunk

    Unleash the power of Splunk Observability   Watch Now In this can't miss Tech Talk! The Splunk Growth ...

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...

Welcome to the Splunk Community!

(view in My Videos) We're so glad you're here! The Splunk Community is place to connect, learn, give back, and ...