Splunk Search

how can i modify multivalued field?

sfatnass
Contributor

hi,
how can i change the content of multivalued field using regex.

i have a multivalued field and i try to modify the values, but nothing match with my regex.

how can i do?

thx

0 Karma

woodcock
Esteemed Legend

I always use rex. It will run against all values. For example, try this to replace all spaces with underscores in all values of field MyField.

... | rex field=MyField mode=sed "s/ /_/g"

Richfez
SplunkTrust
SplunkTrust

Hi, sfatnass,

Can you provide

  • an example of the multivalued field
  • the command you are trying to run against it
  • a description of what you are trying to do

Thanks!

0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...