Splunk Search

map command usage for a adding a new column

joydeep741
Path Finder

I have a
SEARCH-1
Which Gives results like

-time column1 column2

I want to run a secondary search for each value of _time and add a column3 added to the existing columns in the result above.

-time column1 column2 column3

I am trying something like this. My old columns get lost in the process. And the number of results are also less.

index=abc sourcetype=sitescopev2log | timechart avg(Availability) by columns | map search="search index=xyz sourcetype=xyz_st | stats count as column3"

Tags (2)
0 Karma

woodcock
Esteemed Legend

Like this:

index=abc sourcetype=sitescopev2log | timechart avg(Availability) BY columns
| append [index=xyz sourcetype=xyz_st | timechart count AS column3]
| timechart avg(*) AS *
0 Karma
Get Updates on the Splunk Community!

[Puzzles] Solve, Learn, Repeat: Dynamic formatting from XML events

This challenge was first posted on Slack #puzzles channelFor a previous puzzle, I needed a set of fixed-length ...

Enter the Agentic Era with Splunk AI Assistant for SPL 1.4

  🚀 Your data just got a serious AI upgrade — are you ready? Say hello to the Agentic Era with the ...

Stronger Security with Federated Search for S3, GCP SQL & Australian Threat ...

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...