Splunk Search

How can I reverse the x and y axes?

kennethyeung
New Member

current I have this search:

......||addcoltotals | table *_August_R | reverse | head 1 

1_Ausgust_R,2_Ausgust_R,3_Ausgust_R,4_Ausgust_R,
26                    30                   15                       27

I want to change it to

Date, Number
1_August, 26
2_August, 30
3_August, 15
3_August, 27
0 Karma
1 Solution

HiroshiSatoh
Champion

Try this!

    ......|addcoltotals | table *_August_R | reverse | head 1
|transpose|rename column as Date,"row 1" as Number|eval Date=substr(Date,1,len(Date)-2)

View solution in original post

0 Karma

HiroshiSatoh
Champion

Try this!

    ......|addcoltotals | table *_August_R | reverse | head 1
|transpose|rename column as Date,"row 1" as Number|eval Date=substr(Date,1,len(Date)-2)
0 Karma

kennethyeung
New Member

1 more question now, if
......||addcoltotals | table *_August_R , *_August_A| reverse | head 1
1_Ausgust_R,2_Ausgust_R,3_Ausgust_R,4_Ausgust_R, 1_August_R , 2_August_R
26 30 15 27 5 20

want to do below
Date , Number, Another Number
1_August, 26, 5
2_August, 30, 20
.....

how do i use eval but base on other col

0 Karma
Get Updates on the Splunk Community!

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...

What’s New in Splunk Security Essentials 3.8.0?

Splunk Security Essentials (SSE) is an app that can amplify the power of your existing Splunk Cloud Platform, ...

Let’s Get You Certified – Vegas-Style at .conf24

Are you ready to level up your Splunk game? Then, let’s get you certified live at .conf24 – our annual user ...