Splunk Search

where clause issues/stripping out extraneous characters

a212830
Champion

Hi,

I need to do a where clause on a value that includes a % in the result, how can I strip off the percentage character so I can do a numerical where evaluation?

11:06:44 05/07/2015 good 1048333195 [Linux][Baseline][lrtp23][FileSystem][/boot] FileSystems\/boot\Use%=47% 7:45845 0 47

The "Use%" is a field, but the values get the percentage stored with them.

Tags (2)
0 Karma
1 Solution

woodcock
Esteemed Legend

Try this:

... | eval NoPct=rtrim(Use%,"%")

View solution in original post

woodcock
Esteemed Legend

Try this:

... | eval NoPct=rtrim(Use%,"%")
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!

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 ...

Can’t Make It to Boston? Stream .conf25 and Learn with Haya Husain

Boston may be buzzing this September with Splunk University and .conf25, but you don’t have to pack a bag to ...