Splunk Search

Regex help connected string

moinyuso96
Path Finder

I would like to extract two groups which are TestName and Model. In the second row, the TestName is connected to Model cannot be extracted as two different groups.

Link for regex:

regex101: build, test, and debug regex

Labels (2)
0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust

Is it always MY followed by digits?

(?P<TestName>(?<=!\s)[^\s]+)\s?(?P<Model>MY\d+)

View solution in original post

ITWhisperer
SplunkTrust
SplunkTrust

Is it always MY followed by digits?

(?P<TestName>(?<=!\s)[^\s]+)\s?(?P<Model>MY\d+)

moinyuso96
Path Finder

Yes

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