Splunk Search

timechart per month even if some months are missing data

claatu
Explorer

I have this search:
index=alpha asset_id=100 | timechart span=1mon latest(score) by asset_id

This gives me a chart with data in some months, but for months without data, blanks. What I want is the latest value (score) as is seen by any given month, up to that time. And the chart would have the latest 6 months. So given these months and data:

2-2017 : 1
3-2017 : 2
4-2017 : 3
5-2017 : no data
6-2017 : 4
7-2017 : no data
8-2017 : 6
9-2017 : no data
10-2017 : 7
11-2017 : no data
12-2017 : no data

The chart I want to end up with is:
7-2017 : 4
8-2017 : 6
9-2017 : 6
10-2017 : 7
11-2017 : 7
12-2017 : 7

suggestions?

0 Karma
1 Solution

somesoni2
Revered Legend

Try this

index=alpha asset_id=100 | timechart span=1mon latest(score) by asset_id | filldown *

View solution in original post

somesoni2
Revered Legend

Try this

index=alpha asset_id=100 | timechart span=1mon latest(score) by asset_id | filldown *

claatu
Explorer

Perfect! And all too easy...thanks!

0 Karma
Get Updates on the Splunk Community!

Earn a $35 Gift Card for Answering our Splunk Admins & App Developer Survey

Survey for Splunk Admins and App Developers is open now! | Earn a $35 gift card!      Hello there,  Splunk ...

Continuing Innovation & New Integrations Unlock Full Stack Observability For Your ...

You’ve probably heard the latest about AppDynamics joining the Splunk Observability portfolio, deepening our ...

Monitoring Amazon Elastic Kubernetes Service (EKS)

As we’ve seen, integrating Kubernetes environments with Splunk Observability Cloud is a quick and easy way to ...