<?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 do I extract fields in line separated data without key-value pair? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-extract-fields-in-line-separated-data-without-key-value/m-p/44920#M10618</link>
    <description>&lt;P&gt;That's great, thanks!&lt;/P&gt;</description>
    <pubDate>Fri, 06 Jan 2012 08:33:29 GMT</pubDate>
    <dc:creator>melonman</dc:creator>
    <dc:date>2012-01-06T08:33:29Z</dc:date>
    <item>
      <title>How do I extract fields in line separated data without key-value pair?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-extract-fields-in-line-separated-data-without-key-value/m-p/44918#M10616</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I have a logfile containing data that looks like the below:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Nov 21 13:59:41
hostname1
data1
data2
data3
Nov 21 13:59:42
hostname1
data1
data2
data3
Nov 21 13:59:43
hostname1
data1
data2
data3
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I would like to extract hostname, and each data in a separate line.&lt;BR /&gt;
How can I configure the regex to get such fields?&lt;/P&gt;

&lt;P&gt;Thanks in advance,&lt;/P&gt;</description>
      <pubDate>Thu, 05 Jan 2012 13:37:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-extract-fields-in-line-separated-data-without-key-value/m-p/44918#M10616</guid>
      <dc:creator>melonman</dc:creator>
      <dc:date>2012-01-05T13:37:26Z</dc:date>
    </item>
    <item>
      <title>Re: How do I extract fields in line separated data without key-value pair?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-extract-fields-in-line-separated-data-without-key-value/m-p/44919#M10617</link>
      <description>&lt;P&gt;Splunk should already parse out each section, splitting on the timestamp, to a separate "record".  This regex will work for the sample you've provided:&lt;/P&gt;

&lt;P&gt;rex "(?m)(?&lt;TIMESTAMP&gt;.&lt;EM&gt;+)\n(?&lt;HOSTNAME&gt;.&lt;/HOSTNAME&gt;&lt;/EM&gt;+)\n(?&lt;DATA_1&gt;.&lt;EM&gt;+)\n(?&lt;DATA_2&gt;.&lt;/DATA_2&gt;&lt;/EM&gt;+)\n(?&lt;DATA_3&gt;.*+)"&lt;/DATA_3&gt;&lt;/DATA_1&gt;&lt;/TIMESTAMP&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Jan 2012 23:51:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-extract-fields-in-line-separated-data-without-key-value/m-p/44919#M10617</guid>
      <dc:creator>sbrant_tt</dc:creator>
      <dc:date>2012-01-05T23:51:13Z</dc:date>
    </item>
    <item>
      <title>Re: How do I extract fields in line separated data without key-value pair?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-extract-fields-in-line-separated-data-without-key-value/m-p/44920#M10618</link>
      <description>&lt;P&gt;That's great, thanks!&lt;/P&gt;</description>
      <pubDate>Fri, 06 Jan 2012 08:33:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-extract-fields-in-line-separated-data-without-key-value/m-p/44920#M10618</guid>
      <dc:creator>melonman</dc:creator>
      <dc:date>2012-01-06T08:33:29Z</dc:date>
    </item>
  </channel>
</rss>

