Dashboards & Visualizations

How to show single value trend?

kiran331
Builder

Hi

How to show the single value trend, showing increase or decrease from last week? I have a data which will be daily i have to show increase OR decrease fr last 7 days, compared to previous 7 days.I'm using below, its not working. Any suggestions?

index=abc|timechart span=7d count

Tags (2)
0 Karma

puneethgowda
Communicator

Stats count by datemday

Select time range last 7 days from the time picker

0 Karma

DalJeanis
Legend

how about

index=abc|timechart span=1d count | delta count p=7 

modified to tell splunk WHAT to delta...(the count field)

kiran331
Builder

I tried its showing No results Found

0 Karma

aaraneta_splunk
Splunk Employee
Splunk Employee

@kiran331 - Were you able to test out DalJeanis' updated solution? Did it work? If yes, please don't forget to resolve this post by clicking on "Accept". If you still need more help, please provide a comment with some feedback. Thanks!

0 Karma

DalJeanis
Legend

My error. Try the new code above.

0 Karma

niketn
Legend

In line with DalJeanis' answer you can use accum to show cumulative upward trend for selected time frame

index=_internal sourcetype=splunkd log_level=ERROR
| timechart count 
| accum count as count

Since this is Cumulative or Running total it will always trend upwards. So you can decide color based on trending in scenarios where Running Total remains zero as either red or green and Running Total increasing as other color based on what you have chosen for zero increment.

Notice no span in timechart and I would also leave Single Value trend interval <option name="trendInterval">auto</option> to auto, to let Splunk decide the same based on selected timerange i.e. if Search runs for a day both of them will be hourly and if it runs for a week it will change to daily. You can change them as per your need if you have static time frame.

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
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 ...