All Apps and Add-ons

Sideview Utils: How to create a `chart count by field1, field2` table with drilldown

DennisMohn
Path Finder

I guess I'm again just missing the point somewhere ...

Currently I'm converting some legacy Simple XML Dashboards into more integrated Views with the help of the Sideview Utils Editor.

One of the views is a table with a chart drilldown. The table view shows the result of the base search sourcetype=livelog http_status=* | chart count by host,http_status resulting in a table showing all hosts as rows, the HTTP returncodes as columns, and the numbers in the cells. Clicking on one of the cells opens a line chart displaying the timechart of the respective host.

Now I want to replicate the same view in Sideview Utils.

<module name="Search" autoRun="True">
  <param name="preview">True</param>
  <param name="search">sourcetype=livelog http_status=* |  chart count by host,http_status</param>
  <param name="earliest">-30m@m</param>
  <param name="latest">@m</param>

  <module name="Table">
    <param name="fields">count,host,returncode</param>
  </module>

</module>

This setup only shows one row, listing all 5 hosts. Can someone point out my error?

1 Solution

sideview
SplunkTrust
SplunkTrust

You don't want that "fields" param there. Just remove it.

The fields going into your chart command are host and http_status, but the fields coming out are host and then "200", "404", "500" etc....

That fields param is telling your Table that you want to throw away all the fields and leave only "host" (which is actually there) and "count" and "returncode" which are not actually fields in the data.

View solution in original post

sideview
SplunkTrust
SplunkTrust

You don't want that "fields" param there. Just remove it.

The fields going into your chart command are host and http_status, but the fields coming out are host and then "200", "404", "500" etc....

That fields param is telling your Table that you want to throw away all the fields and leave only "host" (which is actually there) and "count" and "returncode" which are not actually fields in the data.

DennisMohn
Path Finder

Just as I thought ... Sometimes you're just blind for the obvious errors 🙂

Thanks a ton, that did it!

0 Karma
Get Updates on the Splunk Community!

Introducing Splunk Enterprise 9.2

WATCH HERE! Watch this Tech Talk to learn about the latest features and enhancements shipped in the new Splunk ...

Adoption of RUM and APM at Splunk

    Unleash the power of Splunk Observability   Watch Now In this can't miss Tech Talk! The Splunk Growth ...

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...