<?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: trying to split one event into multiple events in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703434#M238422</link>
    <description>&lt;P&gt;You could try something like this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eval _raw=body
| multikv forceheader=1&lt;/LI-CODE&gt;&lt;P&gt;Although you may need to rename the fields afterwards&lt;/P&gt;</description>
    <pubDate>Sun, 03 Nov 2024 13:14:55 GMT</pubDate>
    <dc:creator>ITWhisperer</dc:creator>
    <dc:date>2024-11-03T13:14:55Z</dc:date>
    <item>
      <title>trying to split one event into multiple events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703347#M238405</link>
      <description>&lt;P&gt;Please help me to extract multiple values from one single value.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="rukshar_0-1730491613716.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/33326iCEB1EB30F4BBBD12/image-size/medium?v=v2&amp;amp;px=400" role="button" title="rukshar_0-1730491613716.png" alt="rukshar_0-1730491613716.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 01 Nov 2024 20:13:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703347#M238405</guid>
      <dc:creator>rukshar</dc:creator>
      <dc:date>2024-11-01T20:13:46Z</dc:date>
    </item>
    <item>
      <title>Re: trying to split one event into multiple events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703349#M238406</link>
      <description>&lt;P&gt;What do you mean by "split"? This is obviously not an event but a result of a search. So adjust your search to not merge all results into multivalued fields (which by the way give you no guarantee that "the same" row from each of those fields correspond to the same event in the original data or whatever data you're summarizing it from).&lt;/P&gt;</description>
      <pubDate>Fri, 01 Nov 2024 21:25:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703349#M238406</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2024-11-01T21:25:38Z</dc:date>
    </item>
    <item>
      <title>Re: trying to split one event into multiple events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703367#M238407</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/231884"&gt;@PickleRick&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;&lt;BR /&gt;Yes, this is the search on the basis of email logs which is giving me one result and i need that search to be multivalued not single valued as you can see in my snippet its giving statistics 1 rather than 3131 which is actually there in the data.&lt;BR /&gt;&lt;BR /&gt;LOGS:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="rukshar_0-1730517118707.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/33327iE88223B0EBD0D0F2/image-size/medium?v=v2&amp;amp;px=400" role="button" title="rukshar_0-1730517118707.png" alt="rukshar_0-1730517118707.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;I need this 3131 to be spiltted into mutiple rows with my other following fields as shown in the previous screenshot. when i am doing mvexpand Computer_name its coming 3131 but as soon as i am applying other fields its not showing the data.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="rukshar_1-1730517345530.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/33328i4E2FA24FB7CA407D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="rukshar_1-1730517345530.png" alt="rukshar_1-1730517345530.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 02 Nov 2024 03:24:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703367#M238407</guid>
      <dc:creator>rukshar</dc:creator>
      <dc:date>2024-11-02T03:24:18Z</dc:date>
    </item>
    <item>
      <title>Re: trying to split one event into multiple events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703374#M238408</link>
      <description>&lt;P&gt;Ouch.&lt;/P&gt;&lt;P&gt;This is a very ugly data.&lt;/P&gt;&lt;P&gt;It's not only unnecessarily complicated and needs a lot of "untangling" to get it parsed properly (so that you cannot write reasonable extractions) it also contains a huge blob of stuff that is effectively separate data points. So if you want to search for just one pf those hosts, you still have to make Splunk dig through whole load of completely irrelevant data.&lt;/P&gt;&lt;P&gt;Additionally, you &lt;EM&gt;are&lt;/EM&gt; doing something to your data because the &lt;EM&gt;body&lt;/EM&gt; field if simply extracted from the json would have just have a long string, not separate fields.&lt;/P&gt;&lt;P&gt;So maybe just post your search as it is. My glass orb is being fixed as we speak.&lt;/P&gt;</description>
      <pubDate>Sat, 02 Nov 2024 10:16:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703374#M238408</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2024-11-02T10:16:03Z</dc:date>
    </item>
    <item>
      <title>Re: trying to split one event into multiple events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703385#M238409</link>
      <description>Please just post your current query inside code block "&amp;lt;/&amp;gt;" button when you write your post.&lt;BR /&gt;Then mockup what and how you want too see the result. One picture is usually better than thousand words.</description>
      <pubDate>Sat, 02 Nov 2024 13:24:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703385#M238409</guid>
      <dc:creator>isoutamo</dc:creator>
      <dc:date>2024-11-02T13:24:38Z</dc:date>
    </item>
    <item>
      <title>Re: trying to split one event into multiple events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703387#M238410</link>
      <description>&lt;P&gt;This is the query i am using in my search.&amp;nbsp;&lt;SPAN&gt;I need my output into mutiple rows.(snippet provided)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;index=mail "*tanium*"
|spath body
|rex field=body max_match=0 "\"(?&amp;lt;Computer_name&amp;gt;.*)\",\"ACN"
|rex field=body max_match=0 "\"(?&amp;lt;Computer_name1&amp;gt;.*)\",\"\[n"
|rex field=Computer_name1 max_match=0 "(?&amp;lt;Computer_name2&amp;gt;.*)\",\"\[n"
|rex field=body max_match=0 "\,(?&amp;lt;Patch_List_Name1&amp;gt;.*)\"\["
|rex field=Patch_List_Name1 max_match=0 "\"(?&amp;lt;Patch_List_Name&amp;gt;.*)\",\""
|rex field=Patch_List_Name1 max_match=0 "\",\""(?&amp;lt;Compliance_status&amp;gt;.*)\"
|eval Computer_name=mvappend(Computer_name,Computer_name2)
|table Computer_name Compliance_status Patch_List_Name&lt;/LI-CODE&gt;
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="rukshar_1-1730555096393.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/33332iA8F12D85EC50125A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="rukshar_1-1730555096393.png" alt="rukshar_1-1730555096393.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 02 Nov 2024 14:08:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703387#M238410</guid>
      <dc:creator>rukshar</dc:creator>
      <dc:date>2024-11-02T14:08:38Z</dc:date>
    </item>
    <item>
      <title>Re: trying to split one event into multiple events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703409#M238411</link>
      <description>&lt;P&gt;Ok. So you are simply extracting the fields using some predefined "anchor points". You are in for a treat if ever your "constant" parts of your event change.&lt;/P&gt;&lt;P&gt;It would be best if you could - as I said at the beginning - do something with the data as it goes into your system. Without it any searching across your data will be hugely inefficient.&lt;/P&gt;&lt;P&gt;In current situation it would probably be best to extract whole rows, then do mvexpand and then extract single fields from each line. You could do it by "counting" quotes but there's one caveat. It's trivial if you assume your field's contents cannot contain escaped quotes. It's getting a bit tricky if you can have escaped quotes. It's getting annoyingly complicated if you can have escaped quotes and escaped backslashes in your field values,&lt;/P&gt;</description>
      <pubDate>Sat, 02 Nov 2024 18:57:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703409#M238411</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2024-11-02T18:57:50Z</dc:date>
    </item>
    <item>
      <title>Re: trying to split one event into multiple events</title>
      <link>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703434#M238422</link>
      <description>&lt;P&gt;You could try something like this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eval _raw=body
| multikv forceheader=1&lt;/LI-CODE&gt;&lt;P&gt;Although you may need to rename the fields afterwards&lt;/P&gt;</description>
      <pubDate>Sun, 03 Nov 2024 13:14:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/trying-to-split-one-event-into-multiple-events/m-p/703434#M238422</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2024-11-03T13:14:55Z</dc:date>
    </item>
  </channel>
</rss>

