Splunk Search

No results found, I want to show other message!!!

caiyundong
Engager

Search :

index=server1 | table processName porcessCount

result A : search has a results.

processName   processCount

java 14

vi   2

result B : search has no results.

No results found, inspector...

How can i display it below...

processName   processCount

 No Process

Thanks.

Tags (1)
1 Solution

jonuwz
Influencer

Like this :

index=server1 | table processName processCount | appendpipe [ stats count | eval processName="No Process" | eval processCount=0 | where count==0 | fields - count ]

View solution in original post

jonuwz
Influencer

Like this :

index=server1 | table processName processCount | appendpipe [ stats count | eval processName="No Process" | eval processCount=0 | where count==0 | fields - count ]

smolcj
Builder
Get Updates on the Splunk Community!

Detecting Remote Code Executions With the Splunk Threat Research Team

REGISTER NOWRemote code execution (RCE) vulnerabilities pose a significant risk to organizations. If ...

Observability | Use Synthetic Monitoring for Website Metadata Verification

If you are on Splunk Observability Cloud, you may already have Synthetic Monitoringin your observability ...

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...