Splunk Search

How to skip/ignore one letter character from filtered log

Rakesh915473
Explorer

Hello Team,

 rex field=_raw "string_list=%25(?<new_field1>\w+)%25"

 

Above condition will get a word between %25 to %25, If I get any one/two letter word, I want to ignore/skip it.

Thanks for the help in advance.

@field-extraction

Labels (7)
0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust
 rex field=_raw "string_list=%25(?<new_field1>\w{3,})%25"

View solution in original post

0 Karma

ITWhisperer
SplunkTrust
SplunkTrust
 rex field=_raw "string_list=%25(?<new_field1>\w{3,})%25"
0 Karma

Rakesh915473
Explorer

Great @ITWhisperer , Thanks :), It's  Working.

Can we also skip/ignore particular word in output.

Ex: Lets say, string_list= '%25USELESSWORD%25, %25HELLO%25'

I want to ignore 'USELESSWORD'.

0 Karma

ITWhisperer
SplunkTrust
SplunkTrust
string_list=(%25USELESSWORD%25,\s*)*%25(?<new_field1>\w{3,})%25
0 Karma

Rakesh915473
Explorer

Thankyou @ITWhisperer 

0 Karma
Get Updates on the Splunk Community!

Observe and Secure All Apps with Splunk

  Join Us for Our Next Tech Talk: Observe and Secure All Apps with SplunkAs organizations continue to innovate ...

Splunk Decoded: Business Transactions vs Business IQ

It’s the morning of Black Friday, and your e-commerce site is handling 10x normal traffic. Orders are flowing, ...

Fastest way to demo Observability

I’ve been having a lot of fun learning about Kubernetes and Observability. I set myself an interesting ...