Dashboards & Visualizations

Data missing from dashboard panel

terryloar
Path Finder

The input log using access_combined source type:

[12/28/2012 4:41:09 PM] [12/28/2012 4:41:10 PM] step_number="1220" step_return_code="0" step_elapsed_time="0 Days 0:0:01"

[12/28/2012 4:41:11 PM] [12/28/2012 4:41:12 PM] step_number="1230" step_return_code="0" step_elapsed_time="0 Days 0:0:01"

[12/28/2012 4:41:13 PM] [12/28/2012 4:41:27 PM] step_number="1500" step_return_code="0" step_elapsed_time="0 Days 0:0:14"

[12/28/2012 4:41:29 PM] [12/28/2012 4:41:44 PM] step_number="2000" step_return_code="0" step_elapsed_time="0 Days 0:0:15"

The search:

source="*_.log" | chart values(step_number) AS "Step Number" values(step_return_code) AS "Return Code" values(step_elapsed_time) AS "Elapsed Time"

The results from the dashboard panel:

_time Step Number Return Code Elapsed Time

12/28/12 4:40:34.000 PM 1220 0 0 Days 0:0:01

                              1230

12/28/12 4:41:12.000 PM 1500 0 0 Days 0:0:12

                              2000          0 Days 0:0:12

                              2010          0 Days 0:0:14

I can't figure out why the Return Code and Elapsed Time are missing from Step 1230, and why the Return Code is missing from Steps 2000 and 2010,

It should look like this:

_time Step Number Return Code Elapsed Time

12/28/12 4:40:34.000 PM 1220 0 0 Days 0:0:01

Tags (1)
0 Karma

Ayn
Legend

From the docs on stats functions:

values(X)   This function returns the list of all distinct values of the field X as a multi-value entry. The order of the values is lexicographical.

So, you're using values() to list all distinct values in your events, and that's what you get. The only distinct value for step_return_code is 0.

I'm not sure if you really should be using values here. Wouldn't it be a better idea to use a table instead? That way you get values per event instead of aggregated like it is now.

... | table step_number step_return_code step_elapsed_time
0 Karma
Get Updates on the Splunk Community!

The OpenTelemetry Certified Associate (OTCA) Exam

What’s this OTCA exam? The Linux Foundation offers the OpenTelemetry Certified Associate (OTCA) credential to ...

From Manual to Agentic: Level Up Your SOC at Cisco Live

Welcome to the Era of the Agentic SOC   Are you tired of being a manual alert responder? The security ...

Splunk Classroom Chronicles: Training Tales and Testimonials (Episode 4)

Welcome back to Splunk Classroom Chronicles, our ongoing series where we shine a light on what really happens ...