<?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: Multivalue fields in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-Multivalue-fields/m-p/600583#M209070</link>
    <description>&lt;P&gt;This was exactly what I was looking for, thanks.&lt;/P&gt;</description>
    <pubDate>Sun, 05 Jun 2022 03:04:52 GMT</pubDate>
    <dc:creator>shrek</dc:creator>
    <dc:date>2022-06-05T03:04:52Z</dc:date>
    <item>
      <title>How to extract Multivalue fields?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-Multivalue-fields/m-p/600581#M209068</link>
      <description>&lt;P&gt;Lets just say I have multiple events like this:&lt;/P&gt;
&lt;TABLE border="1" width="99.61088709677418%"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="50%"&gt;names&lt;/TD&gt;
&lt;TD width="49.612569809118945%"&gt;
&lt;P&gt;John&lt;/P&gt;
&lt;P&gt;Sam&lt;/P&gt;
&lt;P&gt;Todd&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="50%"&gt;favorite_colors&lt;/TD&gt;
&lt;TD width="49.612569809118945%"&gt;
&lt;P&gt;Blue&lt;/P&gt;
&lt;P&gt;Yellow&lt;/P&gt;
&lt;P&gt;Green&lt;/P&gt;
&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;P&gt;Each event might have a different number of field values but the ratio of &lt;STRONG&gt;names &lt;/STRONG&gt;to&amp;nbsp;&lt;STRONG&gt;favorite_colors &lt;/STRONG&gt;is 1:1.&lt;/P&gt;
&lt;P&gt;Is it possible to extract these into new events or display them separately in a table like this:&lt;/P&gt;
&lt;TABLE border="1" width="100%"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="50%"&gt;name&lt;/TD&gt;
&lt;TD width="50%"&gt;favourite_color&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="50%"&gt;John&lt;/TD&gt;
&lt;TD width="50%"&gt;Blue&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="50%"&gt;Sam&lt;/TD&gt;
&lt;TD width="50%"&gt;Yellow&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="50%"&gt;Todd&lt;/TD&gt;
&lt;TD width="50%"&gt;Green&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have tried mvexpand but that only works for 1 multivalue field.&lt;/P&gt;</description>
      <pubDate>Mon, 06 Jun 2022 03:41:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-Multivalue-fields/m-p/600581#M209068</guid>
      <dc:creator>shrek</dc:creator>
      <dc:date>2022-06-06T03:41:42Z</dc:date>
    </item>
    <item>
      <title>Re: Multivalue fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-Multivalue-fields/m-p/600582#M209069</link>
      <description>&lt;P&gt;As you say, mvexpand works on one event, so there are a couple of ways to do it, here is one&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eval row=mvrange(0,mvcount(name))
| mvexpand row
| eval name=mvindex(name,row)
| eval favourite_colour=mvindex(favourite_colour,row)
| fields - row&lt;/LI-CODE&gt;</description>
      <pubDate>Sun, 05 Jun 2022 02:23:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-Multivalue-fields/m-p/600582#M209069</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-06-05T02:23:14Z</dc:date>
    </item>
    <item>
      <title>Re: Multivalue fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-Multivalue-fields/m-p/600583#M209070</link>
      <description>&lt;P&gt;This was exactly what I was looking for, thanks.&lt;/P&gt;</description>
      <pubDate>Sun, 05 Jun 2022 03:04:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-Multivalue-fields/m-p/600583#M209070</guid>
      <dc:creator>shrek</dc:creator>
      <dc:date>2022-06-05T03:04:52Z</dc:date>
    </item>
  </channel>
</rss>

