Splunk Search

How to combine two different columns in a table into a single column?

Rukmani_Splunk
Path Finder

I have table as below generated from splunk

     C:x  D:x  E:x  F:x  C:y  D:y  E:y  F:y
A    2    1    0    3    5    6    7    8
B    0    2    8    9    0    8    9    0

I want to get a table as below

       C           D           E           F
A   X:2 Y:5     x:1,Y:6     x:0 Y:7     x:3 Y:8
B   X:0 Y:0     X:2,Y:8     x:8 y:9     x:9 Y:0

Please help me in getting this. Thanks in advance

Tags (3)
0 Karma

somesoni2
Revered Legend

Give this a try (assuming first

your current search giving output1 | untable column1 Metrics Data| rex field=Metrics "(?<Metrics>[^:]+):(?<Term>.+)" | eval Data=Term.":".Data | chart values(Data) over column1 by Metrics
0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Community Content Calendar, September edition

Welcome to another insightful post from our Community Content Calendar! We're thrilled to continue bringing ...

Splunkbase Unveils New App Listing Management Public Preview

Splunkbase Unveils New App Listing Management Public PreviewWe're thrilled to announce the public preview of ...

Leveraging Automated Threat Analysis Across the Splunk Ecosystem

Are you leveraging automation to its fullest potential in your threat detection strategy?Our upcoming Security ...