<?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: How to combine duplicate fields in the same event into one field? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200398#M39593</link>
    <description>&lt;P&gt;if you are not getting two Params being field-extracted, you could use a rex and an eval&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| rex field=_raw "Param=\"(?&amp;lt;p1&amp;gt;[^\"]*)\" Param=\"(?&amp;lt;p2&amp;gt;[^\"]*)\"" | eval param=p1.p2
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Mon, 31 Aug 2015 04:17:10 GMT</pubDate>
    <dc:creator>sduff_splunk</dc:creator>
    <dc:date>2015-08-31T04:17:10Z</dc:date>
    <item>
      <title>How to combine duplicate fields in the same event into one field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200397#M39592</link>
      <description>&lt;P&gt;Hey Guys,&lt;/P&gt;

&lt;P&gt;I have events that contains the same field, like so:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;12/08/2015 1:03:03 PM Server="exchange" User="admin@domain.com" Identity="bigstring=" Cmdlet="Set-DistributionGroup" Param="-IgnoreNamingPolicy 'True'" Param="-Identity 'Distro Group'" Success="True" Error=""
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;So as you can see, my event has 2 param fields for the "set-distributionGroup' cmdlet.&lt;/P&gt;

&lt;P&gt;I am wondering how to combine this field into one. Thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 31 Aug 2015 00:38:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200397#M39592</guid>
      <dc:creator>weznagwama</dc:creator>
      <dc:date>2015-08-31T00:38:58Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine duplicate fields in the same event into one field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200398#M39593</link>
      <description>&lt;P&gt;if you are not getting two Params being field-extracted, you could use a rex and an eval&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| rex field=_raw "Param=\"(?&amp;lt;p1&amp;gt;[^\"]*)\" Param=\"(?&amp;lt;p2&amp;gt;[^\"]*)\"" | eval param=p1.p2
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 31 Aug 2015 04:17:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200398#M39593</guid>
      <dc:creator>sduff_splunk</dc:creator>
      <dc:date>2015-08-31T04:17:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine duplicate fields in the same event into one field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200399#M39594</link>
      <description>&lt;P&gt;Hey mate,&lt;/P&gt;

&lt;P&gt;Thanks for the reply.&lt;/P&gt;

&lt;P&gt;Let's assume an event has '4' seperate Params.&lt;/P&gt;

&lt;P&gt;Is there a way to field extract to match all? Or would I just have to say regex 10 params, eval p1...p10, to catch up to 10 params?&lt;/P&gt;

&lt;P&gt;The issue being that not all events have 2 params...some could have 1 or some could have 6. Thanks again.&lt;/P&gt;</description>
      <pubDate>Mon, 31 Aug 2015 04:32:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200399#M39594</guid>
      <dc:creator>weznagwama</dc:creator>
      <dc:date>2015-08-31T04:32:18Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine duplicate fields in the same event into one field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200400#M39595</link>
      <description>&lt;P&gt;Hi weznagwama,&lt;/P&gt;

&lt;P&gt;I think you can use "makemv" command with "delim"  by mentioning the seperator.&lt;/P&gt;

&lt;P&gt;| makemv delim="-" Cmdlet | top Cmdlet&lt;/P&gt;

&lt;P&gt;-Krishna Rajapantula&lt;/P&gt;</description>
      <pubDate>Mon, 31 Aug 2015 04:41:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200400#M39595</guid>
      <dc:creator>krishnarajapant</dc:creator>
      <dc:date>2015-08-31T04:41:32Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine duplicate fields in the same event into one field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200401#M39596</link>
      <description>&lt;P&gt;If you don't know how many parameters you are going to have, you can have all the params extracted into a multi-value field called 'oneparam', and then use mvjoin to put them into a single parameter (called params). Each field will be separated by a space.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| rex max_match=0 field=_raw "Param=\"(?&amp;lt;oneparam&amp;gt;[^\"]*)\" | eval params=mvjoin(oneparam, " ")
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 31 Aug 2015 04:47:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200401#M39596</guid>
      <dc:creator>sduff_splunk</dc:creator>
      <dc:date>2015-08-31T04:47:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine duplicate fields in the same event into one field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200402#M39597</link>
      <description>&lt;P&gt;If you logs have the format mentioned above (key-value pair), Splunk should've extracted a multivalued field Param already, which will contain both the Param values. Try running this and see if you can see both values under same field name.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;your base search | table Param
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 01 Sep 2015 14:19:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200402#M39597</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2015-09-01T14:19:18Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine duplicate fields in the same event into one field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200403#M39598</link>
      <description>&lt;P&gt;Hey mate, thanks for the reply, I've unfortuntaely got stuck on something else relating to powershell scripts running so can't test this yet....until I get the powershell script working. Will post back once I do.&lt;/P&gt;</description>
      <pubDate>Wed, 02 Sep 2015 04:25:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200403#M39598</guid>
      <dc:creator>weznagwama</dc:creator>
      <dc:date>2015-09-02T04:25:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine duplicate fields in the same event into one field?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200404#M39599</link>
      <description>&lt;P&gt;Thanks for the reply, I've unfortunately gotten stuck on attempting to get a powershell script working (turns out it's quiet difficult.) Will post back once I get that going. Cheers.&lt;/P&gt;</description>
      <pubDate>Wed, 02 Sep 2015 04:25:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-combine-duplicate-fields-in-the-same-event-into-one-field/m-p/200404#M39599</guid>
      <dc:creator>weznagwama</dc:creator>
      <dc:date>2015-09-02T04:25:43Z</dc:date>
    </item>
  </channel>
</rss>

