<?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 Extracting data which is incosistent in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/648810#M224429</link>
    <description>&lt;P&gt;I need to extract a time value from log file where the time value appears with a few different variations of characters around it.&amp;nbsp; I'm struggling with handling all the variations through my regex extract.&lt;/P&gt;&lt;P&gt;Below are examples of each of the variations:&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;ChainedQuery&lt;/SPAN&gt; &lt;SPAN class=""&gt;elapsed&lt;/SPAN&gt; &lt;SPAN class=""&gt;time&lt;/SPAN&gt;&lt;SPAN&gt; [&lt;/SPAN&gt;&lt;SPAN class=""&gt;90&lt;/SPAN&gt;&lt;SPAN&gt;]&lt;/SPAN&gt;&lt;SPAN class=""&gt;ms&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Elapsed time: 114ms&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Elapsed time to get Service pool: 339&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Elapsed Time: 69&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;took 37ms&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Is there a way to extract all the numeric values with 1 regex?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 30 Jun 2023 13:15:47 GMT</pubDate>
    <dc:creator>nateNpgh</dc:creator>
    <dc:date>2023-06-30T13:15:47Z</dc:date>
    <item>
      <title>Extracting data which is incosistent</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/648810#M224429</link>
      <description>&lt;P&gt;I need to extract a time value from log file where the time value appears with a few different variations of characters around it.&amp;nbsp; I'm struggling with handling all the variations through my regex extract.&lt;/P&gt;&lt;P&gt;Below are examples of each of the variations:&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;ChainedQuery&lt;/SPAN&gt; &lt;SPAN class=""&gt;elapsed&lt;/SPAN&gt; &lt;SPAN class=""&gt;time&lt;/SPAN&gt;&lt;SPAN&gt; [&lt;/SPAN&gt;&lt;SPAN class=""&gt;90&lt;/SPAN&gt;&lt;SPAN&gt;]&lt;/SPAN&gt;&lt;SPAN class=""&gt;ms&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Elapsed time: 114ms&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Elapsed time to get Service pool: 339&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Elapsed Time: 69&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;took 37ms&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Is there a way to extract all the numeric values with 1 regex?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jun 2023 13:15:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/648810#M224429</guid>
      <dc:creator>nateNpgh</dc:creator>
      <dc:date>2023-06-30T13:15:47Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting data which is incosistent</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/648812#M224430</link>
      <description>&lt;P&gt;It depends how many different variants you expect to encounter and how fool-proof you want this solution to be. If you go too broadly - for example extracting every sequence of digits after a "elapsed" word (would need a separate branch for the "took" version) - you risk getting unrelated data extracted.&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jun 2023 13:35:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/648812#M224430</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2023-06-30T13:35:36Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting data which is incosistent</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/648813#M224431</link>
      <description>&lt;P&gt;I just need to be able to handle the variations I included.&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jun 2023 13:38:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/648813#M224431</guid>
      <dc:creator>nateNpgh</dc:creator>
      <dc:date>2023-06-30T13:38:03Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting data which is incosistent</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/648814#M224432</link>
      <description>&lt;P&gt;Just use an alternative within a group and you're set.&lt;/P&gt;&lt;PRE&gt;(Prefix1|prefix2|prefix3)(?&amp;lt;capture_field&amp;gt;\d+)&lt;/PRE&gt;</description>
      <pubDate>Fri, 30 Jun 2023 13:41:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/648814#M224432</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2023-06-30T13:41:24Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting data which is incosistent</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/649190#M224500</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;With those examples this should work&amp;nbsp;&lt;A href="https://regex101.com/r/jBOkh7/1" target="_blank"&gt;https://regex101.com/r/jBOkh7/1&lt;/A&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;\s+[\[]?(\d+)&lt;/LI-CODE&gt;&lt;P&gt;But this expecting that in field where you are extracting these values haven't been anything else. If those contains other text you need to modify that.&lt;/P&gt;&lt;P&gt;r. Ismo&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jul 2023 17:34:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-data-which-is-incosistent/m-p/649190#M224500</guid>
      <dc:creator>isoutamo</dc:creator>
      <dc:date>2023-07-04T17:34:49Z</dc:date>
    </item>
  </channel>
</rss>

