Dashboards & Visualizations

timerange for the history command

paulathome
Path Finder

I've noticed that running the "| history" command will return different results based on the setting of the timerangepicker. So my question is how can I define the earliest and latest values within the search bar, or in a dashboard panel's query?

| history earliest=-24h                 does not work
earliest=-24h | history                 does not work

and I'm fairly confident that anything downstream from the history command won't be able to influence how many results were delivered initially by the history command.

0 Karma
1 Solution

paulathome
Path Finder

I was using this in a dashboard panel to nicely display the last few searches that a user performed and I was able to set the earliest and latest in the Search module. Couple that with a Pager, Table, HTML and a redirector module I was all set.

Thanks Sideview Utils,
Paul

View solution in original post

0 Karma

somesoni2
Revered Legend

You would not be able to add earliest or latest value in a query (within search bar or a dashboard query) involving '|history'. The only option is the use timerangepicker (from searchbar) or from param "earliest" or latest within dashboard xml.

paulathome
Path Finder

I was using this in a dashboard panel to nicely display the last few searches that a user performed and I was able to set the earliest and latest in the Search module. Couple that with a Pager, Table, HTML and a redirector module I was all set.

Thanks Sideview Utils,
Paul

0 Karma
Get Updates on the Splunk Community!

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...

New in Observability Cloud - Explicit Bucket Histograms

Splunk introduces native support for histograms as a metric data type within Observability Cloud with Explicit ...