Dashboards & Visualizations

How do I display the current date (month and year) in the title of a dashboard?

chris_thuys
Path Finder

How can I display the current month and year ie "January 2015" in the title of a dashboard, ( not the search date)

Tags (4)
0 Karma

risgupta
Path Finder

/code
| makeresults
| eval prevWeekDate=strftime((now(),"-7d"),"%Y/%m/%d")
| table prevWeekDate
1

$result.prevWeekDate$

0 Karma

lguinn2
Legend

Ah, this requires a trick or two. You can't really put the date in a heading, but you could create a single value panel at the top of the dashboard, and this single value panel could contain the following search:

index=main | head 1 | eval month_year=strftime(now(),"%B %Y") | table month_year

Actually, I'll bet that you can put the data in a heading, if you write some javascript etc. I think the above method is pretty simple.

0 Karma

chris_thuys
Path Finder

Thanks for that. I'll try it out.

0 Karma
Get Updates on the Splunk Community!

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 ...

Tech Talk | Elevating Digital Service Excellence: The Synergy of Splunk RUM & APM

Elevating Digital Service Excellence: The Synergy of Real User Monitoring and Application Performance ...

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 ...