Splunk Search

How to convert string into percentage

shravanikarale
Loves-to-Learn Lots

I want to convert a column of text values into  percentage.

STATUS
ontime
late
ontime
late
Labels (1)
0 Karma

to4kawa
Ultra Champion
| makeresults
| eval _raw="STATUS
ontime
late
ontime
late"
| multikv
| top STATUS

try top

0 Karma

shravanikarale
Loves-to-Learn Lots

But what if I don't know how many times ontime and late has occured and i have to convert it based on customer name. For example my excel sheet looks like this:

customerSTATUS
ALEXontime
CHRISlate
ALEXlate
DAVEontime
ALEXontime
CHRISontime
ALEXlate

 how can i calculate STATUS based on customer name in percentage format?

0 Karma

to4kawa
Ultra Champion

 

| makeresults
| eval _raw="customer	STATUS
ALEX	ontime
CHRIS	late
ALEX	late
DAVE	ontime
ALEX	ontime
CHRIS	ontime
ALEX	late"
| multikv forceheader=1 
| top customer STATUS

 

Well, Have you tried top? 

0 Karma
Get Updates on the Splunk Community!

What’s New & Next in Splunk SOAR

Security teams today are dealing with more alerts, more tools, and more pressure than ever.  Join us on ...

Your Voice Matters! Help Us Shape the New Splunk Lantern Experience

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

September Community Champions: A Shoutout to Our Contributors!

As we close the books on another fantastic month, we want to take a moment to celebrate the people who are the ...