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!

Splunk + ThousandEyes: Correlate frontend, app, and network data to troubleshoot ...

 Are you tired of troubleshooting delays caused by siloed frontend, application, and network data? We've got a ...

Splunk Observability for AI

Don’t miss out on an exciting Tech Talk on Splunk Observability for AI!Discover how Splunk’s agentic AI ...

🔐 Trust at Every Hop: How mTLS in Splunk Enterprise 10.0 Makes Security Simpler

From Idea to Implementation: Why Splunk Built mTLS into Splunk Enterprise 10.0  mTLS wasn’t just a checkbox ...