Splunk Search

splunk

vinod0313
Explorer

I have two queries and i want to append those two queries and i need new column for separation
for ex:
i got below result from query 1

total     avg       max
10          15         16


and i got below result from query 2
total     avg       max
51          50        19


i want to append both queries and I want result like below

Name       total   avg    max
first           10         15       16
second     51         50        19

 

 

 

So I want new column with "Name"

could anyone please help on this??

Labels (1)
0 Karma

saravanan90
Contributor

append command may help..  Query1 | eval Name="first"  | append [|search query2| eval Name="second"] 

index=_internal | stats avg(kbps) as avg, max(kbps) as max,sum(kbps) as total | eval Name="_internal"| append [search index=_audit| stats avg(kbps) as avg, max(kbps) as max,sum(kbps) as total | eval Name="_audit"] | table Name avg max total

0 Karma
Get Updates on the Splunk Community!

Accelerating Observability as Code with the Splunk AI Assistant

We’ve seen in previous posts what Observability as Code (OaC) is and how it’s now essential for managing ...

Integrating Splunk Search API and Quarto to Create Reproducible Investigation ...

 Splunk is More Than Just the Web Console For Digital Forensics and Incident Response (DFIR) practitioners, ...

Congratulations to the 2025-2026 SplunkTrust!

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