Dashboards & Visualizations

How to custom format a time token to be rendered in a label?

nl65
Explorer

I have a panel that displays a timechart.

Clicking a bar on the chart drills down to another dashboard passing the click.name as a parameter:

<drilldown target="_blank">
<link>
      <![CDATA[generaloverviewrange?clicked_time=$click.value$]]>
</link>
</drilldown>

I would like to generate a label for the new dashboard containing the selected time formatted as:

strptime("%m/%d/%Y",$click_time$)

How?

stephane_cyrill
Builder

Hi nl65, try this:

strptime( "$click_time$", "%m/%d/%Y %H:%M:%S" )

0 Karma

nl65
Explorer

I need the evaluated value - the title shows the string: strptime("$click_time$","%m/%d/%Y")

0 Karma
Get Updates on the Splunk Community!

Splunk Observability for AI

Don’t miss out on an exciting Tech Talk on Splunk Observability for AI!Discover how Splunk’s agentic AI ...

Splunk Enterprise Security 8.x: The Essential Upgrade for Threat Detection, ...

Watch On Demand the Tech Talk on November 6 at 11AM PT, and empower your SOC to reach new heights! Duration: ...

Splunk Observability as Code: From Zero to Dashboard

For the details on what Self-Service Observability and Observability as Code is, we have some awesome content ...