<?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: Is it possible to remove a string from _raw in a search using wildcards with the replace command? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Is-it-possible-to-remove-a-string-from-raw-in-a-search-using/m-p/196319#M56610</link>
    <description>&lt;P&gt;I am not sure that replace could do this well given that we are talking about scanning the entire raw event. You could however use rex in sed mode to replace the string at search time, you could also use a sed transform at index time which might help search performance if your _raw fields are large and you notice a performance impact:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[your search] | rex field=_raw mode=sed "s/M4450G//g"
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Tue, 20 Jan 2015 23:05:58 GMT</pubDate>
    <dc:creator>chanfoli</dc:creator>
    <dc:date>2015-01-20T23:05:58Z</dc:date>
    <item>
      <title>Is it possible to remove a string from _raw in a search using wildcards with the replace command?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-it-possible-to-remove-a-string-from-raw-in-a-search-using/m-p/196318#M56609</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;

&lt;P&gt;I'm trying to remove a string from the _raw of my search with the replace command and was wondering if wildcards are available.&lt;/P&gt;

&lt;P&gt;My data looks something like: BlahBlah &lt;B&gt;M4550G&lt;/B&gt;ImportantStuffi&lt;BR /&gt;
I'm trying to replace "M4550G" with the empty string.&lt;/P&gt;

&lt;P&gt;Is this possible? The string "M4550G" can have any numbers but the M and G will always be there.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Jan 2015 22:57:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-it-possible-to-remove-a-string-from-raw-in-a-search-using/m-p/196318#M56609</guid>
      <dc:creator>rlough</dc:creator>
      <dc:date>2015-01-20T22:57:23Z</dc:date>
    </item>
    <item>
      <title>Re: Is it possible to remove a string from _raw in a search using wildcards with the replace command?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-it-possible-to-remove-a-string-from-raw-in-a-search-using/m-p/196319#M56610</link>
      <description>&lt;P&gt;I am not sure that replace could do this well given that we are talking about scanning the entire raw event. You could however use rex in sed mode to replace the string at search time, you could also use a sed transform at index time which might help search performance if your _raw fields are large and you notice a performance impact:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[your search] | rex field=_raw mode=sed "s/M4450G//g"
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 20 Jan 2015 23:05:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-it-possible-to-remove-a-string-from-raw-in-a-search-using/m-p/196319#M56610</guid>
      <dc:creator>chanfoli</dc:creator>
      <dc:date>2015-01-20T23:05:58Z</dc:date>
    </item>
  </channel>
</rss>

