Splunk Search

Add certain feilds to an existing query to filter the count

bapun18
Communicator

Below is my existing query :

bapun18_0-1597737180744.png

i want to add ceratin common feilds with different value for the respective indexes .How can i add and get the filter count of events .Please help me in tuning the query ASAP

here's attaching the different feilds for respective indexes  :

 

bapun18_1-1597737550135.png

 

Labels (1)
0 Karma

FrankVl
Ultra Champion

It's not very clear to me what you are asking for to be honest.

If you want to apply similar filters to your tstats query like you are showing in your second screenshot, take a look at the PREFIX(), CASE() and TERM() directives you can use in the tstats command:

https://docs.splunk.com/Documentation/Splunk/8.0.5/SearchReference/Tstats#Use_PREFIX.28.29_to_aggreg...

http://docs.splunk.com/Documentation/Splunk/8.0.5/Search/UseCASEandTERMtomatchphrases

Note: PREFIX() is only available since Splunk 8

0 Karma

bapun18
Communicator

Please ignore the |search xxxxx line below eval command line.

was trying something forgot to remove that

 

0 Karma
Get Updates on the Splunk Community!

Splunk Mobile: Your Brand-New Home Screen

Meet Your New Mobile Hub  Hello Splunk Community!  Staying connected to your data—no matter where you are—is ...

Introducing Value Insights (Beta): Understand the Business Impact your organization ...

Real progress on your strategic priorities starts with knowing the business outcomes your teams are delivering ...

Enterprise Security (ES) Essentials 8.3 is Now GA — Smarter Detections, Faster ...

As of today, Enterprise Security (ES) Essentials 8.3 is now generally available, helping SOC teams simplify ...