<?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: Search using multiple variables in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Search-using-multiple-variables/m-p/153592#M31217</link>
    <description>&lt;P&gt;Thank you Ayn for the quick answer.  It works perfectly.&lt;/P&gt;

&lt;P&gt;Now for a bit of added complexity.  I've discovered that for one of the event codes, the user field contains a different value than the cn that the others have.  However, the cn is included in a different field.  Is there a way I can say for any event code matching "1234" search the users in "field1", for everything else search the users in "field2".&lt;/P&gt;

&lt;P&gt;Thanks!&lt;/P&gt;</description>
    <pubDate>Fri, 19 Dec 2014 16:14:02 GMT</pubDate>
    <dc:creator>bbeltman</dc:creator>
    <dc:date>2014-12-19T16:14:02Z</dc:date>
    <item>
      <title>Search using multiple variables</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Search-using-multiple-variables/m-p/153589#M31214</link>
      <description>&lt;P&gt;I want to do a search for specific Microsoft event codes, and only for specific users or groups.  The search would look something like this:&lt;/P&gt;

&lt;P&gt;index=microsoft eventCode=$eventCode user=$user&lt;/P&gt;

&lt;P&gt;Basically, the search needs to run for the specified event codes, then narrow it down to only the specific users in a list.&lt;/P&gt;

&lt;P&gt;I have the event codes and users in two separate CSV files, would it be possible to do something like this with inputlookup?&lt;/P&gt;

&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Thu, 18 Dec 2014 21:50:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Search-using-multiple-variables/m-p/153589#M31214</guid>
      <dc:creator>bbeltman</dc:creator>
      <dc:date>2014-12-18T21:50:55Z</dc:date>
    </item>
    <item>
      <title>Re: Search using multiple variables</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Search-using-multiple-variables/m-p/153590#M31215</link>
      <description>&lt;P&gt;Yes, inputlookup would be part of the solution, as part of a subsearch.&lt;/P&gt;

&lt;P&gt;Assuming you have your eventcodes in a lookup called "eventcodes.csv" and users in "users.csv", with the field names "eventCode" and "user" at the top, respectively, you do this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=microsoft [inputlookup eventcodes.csv] [inputlookup users.csv]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This will result in that the subsearches are expanded into search filters, one for each of all eventcode and user values.&lt;/P&gt;</description>
      <pubDate>Thu, 18 Dec 2014 22:11:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Search-using-multiple-variables/m-p/153590#M31215</guid>
      <dc:creator>Ayn</dc:creator>
      <dc:date>2014-12-18T22:11:26Z</dc:date>
    </item>
    <item>
      <title>Re: Search using multiple variables</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Search-using-multiple-variables/m-p/153591#M31216</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;
You have two separate CSV files, i think you can just use fields lookup to add fields in your events,&lt;BR /&gt;
see the procedure in search tutorial manual page 51&lt;BR /&gt;
after that you can begin searched.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=microsoft eventCode=$eventCode user=$user
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 19 Dec 2014 08:54:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Search-using-multiple-variables/m-p/153591#M31216</guid>
      <dc:creator>btt</dc:creator>
      <dc:date>2014-12-19T08:54:03Z</dc:date>
    </item>
    <item>
      <title>Re: Search using multiple variables</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Search-using-multiple-variables/m-p/153592#M31217</link>
      <description>&lt;P&gt;Thank you Ayn for the quick answer.  It works perfectly.&lt;/P&gt;

&lt;P&gt;Now for a bit of added complexity.  I've discovered that for one of the event codes, the user field contains a different value than the cn that the others have.  However, the cn is included in a different field.  Is there a way I can say for any event code matching "1234" search the users in "field1", for everything else search the users in "field2".&lt;/P&gt;

&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Fri, 19 Dec 2014 16:14:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Search-using-multiple-variables/m-p/153592#M31217</guid>
      <dc:creator>bbeltman</dc:creator>
      <dc:date>2014-12-19T16:14:02Z</dc:date>
    </item>
  </channel>
</rss>

