<?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: Help with Regex in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Help-with-Regex/m-p/153947#M43243</link>
    <description>&lt;P&gt;Fantastic.. works a treat. Thank you so much.&lt;/P&gt;

&lt;P&gt;Cheers,&lt;/P&gt;

&lt;P&gt;Alastair&lt;/P&gt;</description>
    <pubDate>Wed, 18 Feb 2015 04:25:59 GMT</pubDate>
    <dc:creator>ahogbin</dc:creator>
    <dc:date>2015-02-18T04:25:59Z</dc:date>
    <item>
      <title>Help with Regex</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-Regex/m-p/153945#M43241</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;

&lt;P&gt;With my virtually non existent skills around regex I am struggling to get an extraction to work &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;I am trying to extract some text after the  third / as per the below&lt;BR /&gt;
[&lt;A href="http://10.91.11.47:1200/WMB_SAFIRE_INT/BCSWebservice/services/ProcessQuoteMB" target="_blank"&gt;http://10.91.11.47:1200/WMB_SAFIRE_INT/BCSWebservice/services/ProcessQuoteMB&lt;/A&gt;]&lt;/P&gt;

&lt;P&gt;The text I want to extract is everything after the 3rd / so WMB_SAFIRE_INT/BCSWebservice/services/ProcessQuoteMB (the text content &amp;amp; length can vary but the start and end point of the text is consistent in that it starts with [http:// and ends with ]).&lt;BR /&gt;
The result is then piped to a field(?) called WS (?)&lt;/P&gt;

&lt;P&gt;Any help or pointers would be very much appreciated&lt;/P&gt;

&lt;P&gt;Cheers,&lt;/P&gt;

&lt;P&gt;Alastair&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 19:01:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-Regex/m-p/153945#M43241</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2020-09-28T19:01:17Z</dc:date>
    </item>
    <item>
      <title>Re: Help with Regex</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-Regex/m-p/153946#M43242</link>
      <description>&lt;P&gt;Very rough attempt below. It should create a new field called WS, but it is specifially setup for 2 digit ip, you can change that to suit your setup&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;rex  field=fieldname  "\[http\:\/\/[0-9]{2}\.[0-9]{2}\.[0-9]{2}\.[0-9]{2}\:[0-9]{4}\/(?&amp;lt;WS&amp;gt;\S+)*\]"
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 18 Feb 2015 03:57:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-Regex/m-p/153946#M43242</guid>
      <dc:creator>ramdaspr</dc:creator>
      <dc:date>2015-02-18T03:57:36Z</dc:date>
    </item>
    <item>
      <title>Re: Help with Regex</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-Regex/m-p/153947#M43243</link>
      <description>&lt;P&gt;Fantastic.. works a treat. Thank you so much.&lt;/P&gt;

&lt;P&gt;Cheers,&lt;/P&gt;

&lt;P&gt;Alastair&lt;/P&gt;</description>
      <pubDate>Wed, 18 Feb 2015 04:25:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-Regex/m-p/153947#M43243</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-02-18T04:25:59Z</dc:date>
    </item>
    <item>
      <title>Re: Help with Regex</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-Regex/m-p/153948#M43244</link>
      <description>&lt;P&gt;Hi Alastair,&lt;BR /&gt;
You should use the following regex for your field due to the fact that IP's can be 3 digit.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;rex field=fieldname "\[http\:\/\/[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+\:[0-9]+\/(?&amp;lt;WS&amp;gt;\S+)*\]"
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The + quantifier in essence says Any amount of any number in the range of 0 - 9&lt;/P&gt;

&lt;P&gt;This should work, I haven't had a chance to test it, but I'm pretty sure it would work.&lt;/P&gt;</description>
      <pubDate>Wed, 18 Feb 2015 09:45:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-Regex/m-p/153948#M43244</guid>
      <dc:creator>markthompson</dc:creator>
      <dc:date>2015-02-18T09:45:05Z</dc:date>
    </item>
  </channel>
</rss>

