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!

Enterprise Security Content Update (ESCU) | New Releases

In January, the Splunk Threat Research Team had one release of new security content via the Splunk ES Content ...

Expert Tips from Splunk Professional Services, Ensuring Compliance, and More New ...

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

Observability Release Update: AI Assistant, AppD + Observability Cloud Integrations & ...

This month’s releases across the Splunk Observability portfolio deliver earlier detection and faster ...