Splunk Search

How to merge two fields values into a single field?

Allampally
Path Finder

Hi,

I have the below stats result

**Service          Method               Action**
Service1                  Method1                 NULL
Service2                  Method2                 NULL
Service3                  NULL                Method3
Service4                  NULL                Method4

Now I want to merge Method and Action Fields into a single field by removing NULL values in both fields.

1 Solution

xpac
SplunkTrust
SplunkTrust

Hey,

This looks like the perfect use case for coalesce():

| eval Method=coalesce(Method, Action)

Read up on its details here:
http://docs.splunk.com/Documentation/Splunk/7.1.0/SearchReference/ConditionalFunctions

View solution in original post

xpac
SplunkTrust
SplunkTrust

Hey,

This looks like the perfect use case for coalesce():

| eval Method=coalesce(Method, Action)

Read up on its details here:
http://docs.splunk.com/Documentation/Splunk/7.1.0/SearchReference/ConditionalFunctions

Get Updates on the Splunk Community!

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

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...

What’s New in Splunk Security Essentials 3.8.0?

Splunk Security Essentials (SSE) is an app that can amplify the power of your existing Splunk Cloud Platform, ...