Dashboards & Visualizations

Extracting BUILDING value using rex

sgulhane5
Explorer

Hi Team,

I've below extensible attributes in message tab, able to extract Assignor ID and it's Value but facing issue for BUILDING and It's Value. I guess because value is under special characters i.e. ["NOI_SEC60_GF"]] 

network_view=default extensible_attributes=[[name="Assignor ID",value="51806153"],[name="BUILDING",value=["NOI_SEC60_GF"]]

I tried few solution but it's not working. @MuS 

Thanks,

Labels (1)
0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust
|rex max_match=0 field=_raw "BUILDING\",value=\[\"(?<Building>[^\"]*)\"\]"

View solution in original post

sgulhane5
Explorer

Thanks a lot @ITWhisperer 

0 Karma

sgulhane5
Explorer

Thanks, @ITWhisperer 

0 Karma

sgulhane5
Explorer

I tried below command

|rex max_match=0 field=_raw "BUILDING\",value=\"(?<Building>.*?)\s*(\w*+)\]"| eval Building= substr(Building, 1, len(Building)-1)|

Tags (2)
0 Karma

ITWhisperer
SplunkTrust
SplunkTrust
|rex max_match=0 field=_raw "BUILDING\",value=\[\"(?<Building>[^\"]*)\"\]"

ITWhisperer
SplunkTrust
SplunkTrust

What have you tried already? If you are using rex and matching against "name" and "value", are you using max_match=0 to get more than one match?

Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Community Content Calendar, September edition

Welcome to another insightful post from our Community Content Calendar! We're thrilled to continue bringing ...

Splunkbase Unveils New App Listing Management Public Preview

Splunkbase Unveils New App Listing Management Public PreviewWe're thrilled to announce the public preview of ...

Leveraging Automated Threat Analysis Across the Splunk Ecosystem

Are you leveraging automation to its fullest potential in your threat detection strategy?Our upcoming Security ...