<?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 I have some data, if the message contains a word which is in a csv file, then results should show in a table. How should I edit my search? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/I-have-some-data-if-the-message-contains-a-word-which-is-in-a/m-p/341528#M62919</link>
    <description>&lt;P&gt;I have some data, if the message contains a word which is in a csv file, then results should show in a table. How should I edit my search?&lt;/P&gt;

&lt;P&gt;I have a csv file which contains keywords like:&lt;/P&gt;

&lt;P&gt;kill&lt;BR /&gt;
 bomb &lt;BR /&gt;
 gun &lt;BR /&gt;
 drugs&lt;BR /&gt;
 Anthrax&lt;BR /&gt;
 Arms&lt;BR /&gt;
 Attack&lt;BR /&gt;
 Atomic&lt;BR /&gt;
If the message contains more than one word like:&lt;/P&gt;

&lt;P&gt;take your gun&lt;BR /&gt;
 kill him&lt;BR /&gt;
And I search like this:&lt;/P&gt;

&lt;P&gt;search | table message, id ,name&lt;BR /&gt;
then results should look like this:&lt;/P&gt;

&lt;P&gt;message  id  name&lt;/P&gt;</description>
    <pubDate>Sat, 22 Apr 2017 02:53:43 GMT</pubDate>
    <dc:creator>nagarjuna280</dc:creator>
    <dc:date>2017-04-22T02:53:43Z</dc:date>
    <item>
      <title>I have some data, if the message contains a word which is in a csv file, then results should show in a table. How should I edit my search?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/I-have-some-data-if-the-message-contains-a-word-which-is-in-a/m-p/341528#M62919</link>
      <description>&lt;P&gt;I have some data, if the message contains a word which is in a csv file, then results should show in a table. How should I edit my search?&lt;/P&gt;

&lt;P&gt;I have a csv file which contains keywords like:&lt;/P&gt;

&lt;P&gt;kill&lt;BR /&gt;
 bomb &lt;BR /&gt;
 gun &lt;BR /&gt;
 drugs&lt;BR /&gt;
 Anthrax&lt;BR /&gt;
 Arms&lt;BR /&gt;
 Attack&lt;BR /&gt;
 Atomic&lt;BR /&gt;
If the message contains more than one word like:&lt;/P&gt;

&lt;P&gt;take your gun&lt;BR /&gt;
 kill him&lt;BR /&gt;
And I search like this:&lt;/P&gt;

&lt;P&gt;search | table message, id ,name&lt;BR /&gt;
then results should look like this:&lt;/P&gt;

&lt;P&gt;message  id  name&lt;/P&gt;</description>
      <pubDate>Sat, 22 Apr 2017 02:53:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/I-have-some-data-if-the-message-contains-a-word-which-is-in-a/m-p/341528#M62919</guid>
      <dc:creator>nagarjuna280</dc:creator>
      <dc:date>2017-04-22T02:53:43Z</dc:date>
    </item>
    <item>
      <title>Re: I have some data, if the message contains a word which is in a csv file, then results should show in a table. How should I edit my search?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/I-have-some-data-if-the-message-contains-a-word-which-is-in-a/m-p/341529#M62920</link>
      <description>&lt;P&gt;Following query creates a dummy lookup using makeresults (In case of lookup file you can use &lt;STRONG&gt;inputlookup&lt;/STRONG&gt; command instead.)&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| makeresults
| eval findPattern="kill,bomb,gun,drugs,Anthrax,Arms,Attack,Atomic"
| makemv delim="," findPattern 
| mvexpand findPattern limit=10
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Splunk's &lt;STRONG&gt;map&lt;/STRONG&gt; command would be able to iterate though the keywords in the previous query&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| map search="| makeresults | eval testData=\"Chuck Norris doesn't need gun to kill\"| eval matched=if(match(testData,\"$findPattern$\"),1,0)"
| search matched="1"
| stats sum(matched) as matched by testData
| table testData, matched
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Combine the above two search which is a run anywhere example.&lt;/P&gt;</description>
      <pubDate>Sun, 23 Apr 2017 08:03:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/I-have-some-data-if-the-message-contains-a-word-which-is-in-a/m-p/341529#M62920</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2017-04-23T08:03:01Z</dc:date>
    </item>
    <item>
      <title>Re: I have some data, if the message contains a word which is in a csv file, then results should show in a table. How should I edit my search?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/I-have-some-data-if-the-message-contains-a-word-which-is-in-a/m-p/341530#M62921</link>
      <description>&lt;P&gt;I have a .csv file whose name is bad.csv in which the column name is eventuei I want that column to be displayed in my report.&lt;BR /&gt;
Please let me know how to pull the .csv file inside the query and display the "eventuei" column in the report.&lt;/P&gt;</description>
      <pubDate>Fri, 05 Oct 2018 07:01:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/I-have-some-data-if-the-message-contains-a-word-which-is-in-a/m-p/341530#M62921</guid>
      <dc:creator>viji261992</dc:creator>
      <dc:date>2018-10-05T07:01:10Z</dc:date>
    </item>
  </channel>
</rss>

