Splunk Search

Search Field Extraction help

lisaac
Path Finder

I have an _raw event with data that I would like to break out into key value pairs. I was wondering if anyone had any suggestions on how to best accomplish this task at search time based on the following data set:

<COL ID='CARDS_ALIAS_ID'>1111111</COL><COL ID='PROFILE_ALIAS_ID'>44444444</COL><COL ID='TXT_MSG_TYP_2'>5555</COL>

I would like to have the fields CARDS_ALIAS_ID, PROFILE_ALIAS_ID, and TXT_MSG_TYP_2.

Tags (3)
0 Karma

gkanapathy
Splunk Employee
Splunk Employee

Seems pretty likely that:

[mysourcetype]
EXTRACT-xml = \<COL\s+ID=\'(?<_KEY_1>[^\']+)\'\>(?<_VAL_1>[^\>]+)\<\/COL\>

should do it.

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