<?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/113813#M30038</link>
    <description>&lt;P&gt;Ah.. yes that is better.. I was wondering why there were no suburbs appearing with more than one name component.&lt;BR /&gt;
Thank you so much again fro all your help.&lt;BR /&gt;
Cheers&lt;BR /&gt;
Alastair&lt;/P&gt;</description>
    <pubDate>Tue, 24 Mar 2015 22:52:24 GMT</pubDate>
    <dc:creator>ahogbin</dc:creator>
    <dc:date>2015-03-24T22:52:24Z</dc:date>
    <item>
      <title>Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113798#M30023</link>
      <description>&lt;P&gt;Hello to all..&lt;/P&gt;

&lt;P&gt;I am attempting (partially succesfully so far) to extract some text. The problem I am having is that it is also extracting unwanted text past the vaue I am (obviously incorrectly) specifying as the end point.&lt;/P&gt;

&lt;P&gt;The string I am trying to extract is (in this example) ALEXANDRIA&lt;BR /&gt;
ALEXANDRIA (attempting to extract the text between &amp;gt; and &amp;lt;)&lt;/P&gt;

&lt;P&gt;The expression I am using is&lt;BR /&gt;
&lt;CODE&gt;rex field=_raw  "\(?\S+)\&amp;lt;"&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;However, when I run the search, I also get the proceeding text in the returned value below:&lt;BR /&gt;
ALEXANDRIANSW2015AUAustralia&lt;/P&gt;

&lt;P&gt;As I say it is sort of working but I am unsure as to how to instruct the expression to stop at the &lt;CODE&gt;&amp;lt;&lt;/CODE&gt; after the suburb name.&lt;/P&gt;

&lt;P&gt;Any help or pointers will be gratefully accepted.&lt;BR /&gt;
---update--&lt;BR /&gt;
The input string is&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;mm:SuburbName&amp;gt;ALEXANDRIA&amp;lt;/mm:SuburbName&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The suburb will vary&lt;/P&gt;

&lt;P&gt;The output I am getting is&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;ALEXANDRIA&amp;lt;/mm:SuburbName&amp;gt;&amp;lt;mm:StateOrProvinceCode&amp;gt;NSW&amp;lt;/mm:StateOrProvinceCode&amp;gt;&amp;lt;mm:PostalCode&amp;gt;2015&amp;lt;/mm:PostalCode&amp;gt;&amp;lt;mm:CountryCode&amp;gt;AU&amp;lt;/mm:CountryCode&amp;gt;&amp;lt;mm:CountryName&amp;gt;Australia&amp;lt;/mm:CountryName&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Cheers all.&lt;/P&gt;

&lt;P&gt;Alastair&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:07:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113798#M30023</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T04:07:30Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113799#M30024</link>
      <description>&lt;P&gt;Can you share a sample of the data set you are trying to work with?&lt;/P&gt;

&lt;P&gt;Please enclose the example within the code sample (5th button on the textbox toolbox) so that the brackets arent removed.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:14:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113799#M30024</guid>
      <dc:creator>ramdaspr</dc:creator>
      <dc:date>2015-03-24T04:14:35Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113800#M30025</link>
      <description>&lt;P&gt;Hello...&lt;/P&gt;

&lt;P&gt;Sorry was just trying to work out how to do that &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;The expression I am using is &lt;CODE&gt;rex field=_raw  "\(?\S+)\&amp;lt;"&lt;/CODE&gt; and the output I am getting is&lt;BR /&gt;
&lt;CODE&gt;ALEXANDRIANSW2015AUAustralia&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;Hope this is as needed&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:17:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113800#M30025</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T04:17:37Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113801#M30026</link>
      <description>&lt;P&gt;Arrgghh.. will try again&lt;/P&gt;

&lt;P&gt;RegEx = "&lt;CODE&gt;rex field=_raw  "\(?\S+)\&amp;lt;"&lt;/CODE&gt;"&lt;/P&gt;

&lt;P&gt;Output&lt;/P&gt;

&lt;P&gt;"&lt;CODE&gt;ALEXANDRIANSW2015AUAustralia&lt;/CODE&gt;"&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:18:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113801#M30026</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T04:18:43Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113802#M30027</link>
      <description>&lt;P&gt;We would need to see the input event so that we can help with the regex query.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:19:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113802#M30027</guid>
      <dc:creator>ramdaspr</dc:creator>
      <dc:date>2015-03-24T04:19:33Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113803#M30028</link>
      <description>&lt;P&gt;Sorry... cannot get the RegEx string to display. Have tried using both &lt;CODE&gt;&lt;/CODE&gt; and "`" but the string keeps getting chopped off.&lt;/P&gt;

&lt;P&gt;Any other suggestions ?&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:19:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113803#M30028</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T04:19:51Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113804#M30029</link>
      <description>&lt;PRE&gt;&lt;CODE&gt;`rex field=_raw  "\&amp;lt;mm\:SuburbName+\&amp;gt;(?&amp;lt;Suburb&amp;gt;\S+)\&amp;lt;"`
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:23:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113804#M30029</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T04:23:14Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113805#M30030</link>
      <description>&lt;P&gt;The input string is&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;mm:SuburbName&amp;gt;ALEXANDRIA&amp;lt;/mm:SuburbName&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The suburb will vary&lt;/P&gt;

&lt;P&gt;The output I am getting is&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;ALEXANDRIA&amp;lt;/mm:SuburbName&amp;gt;&amp;lt;mm:StateOrProvinceCode&amp;gt;NSW&amp;lt;/mm:StateOrProvinceCode&amp;gt;&amp;lt;mm:PostalCode&amp;gt;2015&amp;lt;/mm:PostalCode&amp;gt;&amp;lt;mm:CountryCode&amp;gt;AU&amp;lt;/mm:CountryCode&amp;gt;&amp;lt;mm:CountryName&amp;gt;Australia&amp;lt;/mm:CountryName&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:25:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113805#M30030</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T04:25:26Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113806#M30031</link>
      <description>&lt;P&gt;So I am trying to extract the text string between  &amp;gt; and &amp;lt;  in this case ALEXANDRIA&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:26:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113806#M30031</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T04:26:48Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113807#M30032</link>
      <description>&lt;P&gt;Let me introduce you to my personal savior: &lt;A href="https://regex101.com/"&gt;RegEx101.com&lt;/A&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;(?i)SuburbName\&amp;gt;(?P\w+)\&amp;lt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:34:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113807#M30032</guid>
      <dc:creator>leathej1</dc:creator>
      <dc:date>2015-03-24T04:34:21Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113808#M30033</link>
      <description>&lt;P&gt;Try with this. Seems to work for the same data you have.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;rex field=t "\&amp;lt;mm\:SuburbName\&amp;gt;(?&amp;lt;suburb&amp;gt;\w+)\&amp;lt;.*"
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:34:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113808#M30033</guid>
      <dc:creator>ramdaspr</dc:creator>
      <dc:date>2015-03-24T04:34:51Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113809#M30034</link>
      <description>&lt;P&gt;Fantastic... thank you very much for your help and sorry for the confusion in getting the required data posted &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;Cheers.&lt;/P&gt;

&lt;P&gt;Alastair&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:44:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113809#M30034</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T04:44:39Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113810#M30035</link>
      <description>&lt;P&gt;Thank you for the site link... this will definitely come in handy.&lt;/P&gt;

&lt;P&gt;Cheers,&lt;BR /&gt;
Alastair&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:45:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113810#M30035</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T04:45:44Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113811#M30036</link>
      <description>&lt;P&gt;In addition to @leathej1's resource, this previous Answers post has a bunch of great regex sites as well in case you're interested.&lt;BR /&gt;
&lt;A href="http://answers.splunk.com/answers/153171/is-there-any-online-regex-tool-to-create-regular-e.html"&gt;http://answers.splunk.com/answers/153171/is-there-any-online-regex-tool-to-create-regular-e.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 04:48:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113811#M30036</guid>
      <dc:creator>ppablo</dc:creator>
      <dc:date>2015-03-24T04:48:18Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113812#M30037</link>
      <description>&lt;P&gt;Missed something quite important, the suburb name could include a space which the above answer will not accept as a valid input.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;rex field=_raw "\&amp;lt;mm\:SuburbName\&amp;gt;(?&amp;lt;suburb&amp;gt;[a-zA-Z ]*)\&amp;lt;.*"
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Should work better as a solution there is a space between Z and ] to allow whitespace as an acceptable value in the Suburb Name.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 06:10:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113812#M30037</guid>
      <dc:creator>ramdaspr</dc:creator>
      <dc:date>2015-03-24T06:10:32Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113813#M30038</link>
      <description>&lt;P&gt;Ah.. yes that is better.. I was wondering why there were no suburbs appearing with more than one name component.&lt;BR /&gt;
Thank you so much again fro all your help.&lt;BR /&gt;
Cheers&lt;BR /&gt;
Alastair&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 22:52:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113813#M30038</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T22:52:24Z</dc:date>
    </item>
    <item>
      <title>Re: Help with RegEX</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113814#M30039</link>
      <description>&lt;P&gt;An excellent page full of rather good resources.&lt;BR /&gt;
Thank you for providing this.&lt;BR /&gt;
Cheers,&lt;/P&gt;

&lt;P&gt;Alastair&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2015 22:53:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Help-with-RegEX/m-p/113814#M30039</guid>
      <dc:creator>ahogbin</dc:creator>
      <dc:date>2015-03-24T22:53:10Z</dc:date>
    </item>
  </channel>
</rss>

