Splunk Search

Stats count with lookups

kiran331
Builder

Hello,

I have to get the individual count of three lookups A,B,C. How can I show the count of each lookup n Dashboard in one panel?

search i'm trying:

|inputlookup A.csv |append [|inputlookup B.csv]|append [|inputlookup C.csv]|append [|D.csv] | stats count ???

Tags (2)
1 Solution

sideview
SplunkTrust
SplunkTrust

You should use the inputlookup command's append=t command instead of the append command. (long story)

Here is the approach I would try.

| inputlookup A | eval file="A" | inputlookup append=t B | fillnull file value="B" | inputlookup append=t C | fillnull file value="C" | stats count by file

(Obviously if a field called "file" is actually present in any of these three lookups this wont work very well, but if so just pick a suitable field name.)

View solution in original post

0 Karma

sideview
SplunkTrust
SplunkTrust

You should use the inputlookup command's append=t command instead of the append command. (long story)

Here is the approach I would try.

| inputlookup A | eval file="A" | inputlookup append=t B | fillnull file value="B" | inputlookup append=t C | fillnull file value="C" | stats count by file

(Obviously if a field called "file" is actually present in any of these three lookups this wont work very well, but if so just pick a suitable field name.)

0 Karma
Get Updates on the Splunk Community!

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...