Dashboards & Visualizations

How to add rows to table in dashboard?

JacobWrdz
Explorer

Hello,

I must create a visualization- table. I have several similar tables located at dashboard side by side, the only difference is "Base Level". Client demands the visualization to look aesthetically- that means  the values on the column "Priority difference" should be stable, from -4 to 4 (-4, -3, -2, -1, 0, 1, 2, 3 ,4) and when there would be no logs for that, on the right column "Number" the value should be "0"- like at 1st photo, where I added it manually to visualize the case:

splunk_photo.png

The current final dashboard. At all the dashboards the values on Priority_difference should be always from -4 to 4, now when there are no logs the rows are just missing:splunk_photo2.png

The logs looks like this:


Could you kindly please advise?

Labels (1)
Tags (1)
0 Karma

ITWhisperer
SplunkTrust
SplunkTrust

Not sure why you are using eventstats then dedup when stats will do that in one go

| stats count(Priority_difference) as variable by Priority_difference
| append
    [| makeresults
    | eval Priority_difference=mvrange(-4,5)
    | mvexpand Priority_difference
    | eval variable=0]
| stats sum(variable) as variable by Priority_difference
| sort Priority_difference
| eval Number=variable
| table Priority_difference Number
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

[Puzzles] Solve, Learn, Repeat: Matching cron expressions

This puzzle (first published here) is based on matching timestamps to cron expressions.All the timestamps ...

Design, Compete, Win: Submit Your Best Splunk Dashboards for a .conf26 Pass

Hello Splunkers,  We’re excited to kick off a Splunk Dashboard contest! We know that dashboards are a primary ...

May 2026 Splunk Expert Sessions: Security & Observability

Level Up Your Operations: May 2026 Splunk Expert Sessions Whether you are refining your security posture or ...