<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: merge value from multiple fields into a single field. (Field = Value format) in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-merge-value-from-multiple-fields-into-a-single-field/m-p/585115#M203826</link>
    <description>&lt;P&gt;Thanks perfect!!&lt;/P&gt;</description>
    <pubDate>Tue, 15 Feb 2022 09:00:19 GMT</pubDate>
    <dc:creator>tehong</dc:creator>
    <dc:date>2022-02-15T09:00:19Z</dc:date>
    <item>
      <title>How to merge value from multiple fields into a single field (Field = Value format)?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-merge-value-from-multiple-fields-into-a-single-field/m-p/585102#M203816</link>
      <description>&lt;P&gt;Hi.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to merge data from multiple fields into a single field.&lt;/P&gt;
&lt;P&gt;If you have a table like the following&lt;/P&gt;
&lt;P&gt;fieldA, fieldB, fieldC&lt;BR /&gt;------------------------------&lt;BR /&gt;valueA, valueB, valueC&lt;/P&gt;
&lt;P&gt;The expected output is as follows. I want to combine them into a single field in the Field = Value format.&lt;/P&gt;
&lt;P&gt;merge_data = "fieldA = valueA, fieldB = valueB, fieldC = valueC"&lt;/P&gt;
&lt;P&gt;I think it can be done using multivalue OR foreach, but I don't know how to code it.&lt;/P&gt;
&lt;P&gt;Thanks in advance!!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 17 Feb 2022 00:37:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-merge-value-from-multiple-fields-into-a-single-field/m-p/585102#M203816</guid>
      <dc:creator>tehong</dc:creator>
      <dc:date>2022-02-17T00:37:40Z</dc:date>
    </item>
    <item>
      <title>Re: merge value from multiple fields into a single field. (Field = Value format)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-merge-value-from-multiple-fields-into-a-single-field/m-p/585105#M203819</link>
      <description>&lt;LI-CODE lang="markup"&gt;| eval merge_data=","
| foreach field*
    [| eval merge_data=merge_data."&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;"."=\"".trim(&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;)."\","]
| eval merge_data=trim(merge_data,",")&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 15 Feb 2022 08:00:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-merge-value-from-multiple-fields-into-a-single-field/m-p/585105#M203819</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-02-15T08:00:09Z</dc:date>
    </item>
    <item>
      <title>Re: merge value from multiple fields into a single field. (Field = Value format)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-merge-value-from-multiple-fields-into-a-single-field/m-p/585115#M203826</link>
      <description>&lt;P&gt;Thanks perfect!!&lt;/P&gt;</description>
      <pubDate>Tue, 15 Feb 2022 09:00:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-merge-value-from-multiple-fields-into-a-single-field/m-p/585115#M203826</guid>
      <dc:creator>tehong</dc:creator>
      <dc:date>2022-02-15T09:00:19Z</dc:date>
    </item>
  </channel>
</rss>

