Splunk Enterprise

how to rename the dynamically generated month fields

lostcauz3
Path Finder

I have a table with the following data

080910
datadatadata
datadatadata
datadatadata

 

i want to rename the 08,09,10 to Aug21,Sep21 and Oct21

the field name can be anything from 01 to 12 

01 = Jan21 , 02 = Feb 21, 03 = March21 etc 

How can i rename them in this case.

Labels (1)
0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust
| transpose 0
| eval column=strftime(strptime("01-".column."-21","%d-%m-%y"),"%b%y")
| transpose 0 header_field=column
| fields - column

View solution in original post

0 Karma

ITWhisperer
SplunkTrust
SplunkTrust
| transpose 0
| eval column=strftime(strptime("01-".column."-21","%d-%m-%y"),"%b%y")
| transpose 0 header_field=column
| fields - column
0 Karma

lostcauz3
Path Finder

Thank you!

You've helped me a lot.

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...