Splunk Search

How to display two queries output as single output.

thomas6m
New Member

Hi Team,
How to display two queries output as single output. Please help.
index = * sourcetype=test earliest=@d latest=now | eventstats count as INSTANCES| dedup Microservices | eventstats count as APP | dedup Space | eventstats count as SPACE | dedup Org | eventstats count as ORG | table ORG SPACE APP INSTANCES | head 1

index = * sourcetype=test earliest=@d latest=now |table Instance_state | rename Instance_state as status | stats count(eval(status="running")) AS Running, count(eval(status="down")) AS Down,count(eval(status="crashed")) AS Crashed

Expected Output
ORG SPACE APP INSTANCES Running Down Crashed
3 37 386 820 627 103 90

Tags (2)
0 Karma
1 Solution

richgalloway
SplunkTrust
SplunkTrust
index = * sourcetype=test earliest=@d latest=now 
| rename Instance_state as status 
| stats count(eval(status="running")) AS Running, count(eval(status="down")) AS Down,count(eval(status="crashed")) AS Crashed,
count as INSTANCES, dc(Microservices) as APP, dc(Space) as SPACE, dc(Org) as ORG
| table ORG SPACE APP INSTANCES Running Down Crashed
---
If this reply helps you, Karma would be appreciated.

View solution in original post

0 Karma

richgalloway
SplunkTrust
SplunkTrust
index = * sourcetype=test earliest=@d latest=now 
| rename Instance_state as status 
| stats count(eval(status="running")) AS Running, count(eval(status="down")) AS Down,count(eval(status="crashed")) AS Crashed,
count as INSTANCES, dc(Microservices) as APP, dc(Space) as SPACE, dc(Org) as ORG
| table ORG SPACE APP INSTANCES Running Down Crashed
---
If this reply helps you, Karma would be appreciated.
0 Karma
Get Updates on the Splunk Community!

.conf25 Registration is OPEN!

Ready. Set. Splunk! Your favorite Splunk user event is back and better than ever. Get ready for more technical ...

Detecting Cross-Channel Fraud with Splunk

This article is the final installment in our three-part series exploring fraud detection techniques using ...

Splunk at Cisco Live 2025: Learning, Innovation, and a Little Bit of Mr. Brightside

Pack your bags (and maybe your dancing shoes)—Cisco Live is heading to San Diego, June 8–12, 2025, and Splunk ...