<?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: Problem: Searching for matching fields within multiple source types in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Problem-Searching-for-matching-fields-within-multiple-source/m-p/57466#M11222</link>
    <description>&lt;P&gt;You could combine the searches like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=campusmgr earliest=11/02/2012:23:00:00 latest=11/03/2012:00:23:00 [search sourcetype=msdhcp earliest=11/02/2012:23:00:00 latest=11/03/2012:00:23:00 [search sourcetype=pan:traffic src_translated_port=##### src_translated_ip=###.###.##.## earliest=11/02/2012:23:00:00 latest=11/03/2012:00:23:00 | return 100 src_ip] | return 100 MAC]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;return takes the subsearch results, picks out the specified field (src_ip or MAC) and builds an OR'd chain of up to 100 or however many you like matches, which then get applied to the outer search as a filter. In order for this to work nicely you need to extract the MAC as a field in the campusmgr sourcetype... which probably is a good idea on its own.&lt;/P&gt;</description>
    <pubDate>Mon, 11 Mar 2013 21:20:25 GMT</pubDate>
    <dc:creator>martin_mueller</dc:creator>
    <dc:date>2013-03-11T21:20:25Z</dc:date>
    <item>
      <title>Problem: Searching for matching fields within multiple source types</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-Searching-for-matching-fields-within-multiple-source/m-p/57465#M11221</link>
      <description>&lt;P&gt;I am a new Splunk user who uses Splunk to find infected hosts on our network. I currently run 3 separate searches to pinpoint the users but would like to combine them into one with the goal of ultimately having this e-mailed to myself.&lt;/P&gt;

&lt;P&gt;These are the following searches: &lt;BR /&gt;
sourcetype=pan:traffic src_translated_port=##### src_translated_ip=###.###.##.## earliest=11/02/2012:23:00:00 latest=11/03/2012:00:23:00&lt;/P&gt;

&lt;P&gt;I then review these results to find the src_ip needed to run the subsequent searches.&lt;BR /&gt;
Using the src_ip, I then run this search:&lt;BR /&gt;
sourcetype=msdhcp earliest=11/02/2012:23:00:00 latest=11/03/2012:00:23:00 src_ip=###.###.##.###&lt;/P&gt;

&lt;P&gt;I then review these results to find the MAC address associated with the first two searches.&lt;BR /&gt;
Using the MAC address, I then run this search to determine the user associated with the MAC:&lt;BR /&gt;
sourcetype=campusmgr earliest=11/02/2012:23:00:00 latest=11/03/2012:00:23:00 ##:##:##:##:##:##&lt;/P&gt;

&lt;P&gt;Is there a way to combine these searches into one using map search or the eval commands?&lt;/P&gt;

&lt;P&gt;Any insight would be appreciated. Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 13:29:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-Searching-for-matching-fields-within-multiple-source/m-p/57465#M11221</guid>
      <dc:creator>KNichol5hd</dc:creator>
      <dc:date>2020-09-28T13:29:32Z</dc:date>
    </item>
    <item>
      <title>Re: Problem: Searching for matching fields within multiple source types</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-Searching-for-matching-fields-within-multiple-source/m-p/57466#M11222</link>
      <description>&lt;P&gt;You could combine the searches like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=campusmgr earliest=11/02/2012:23:00:00 latest=11/03/2012:00:23:00 [search sourcetype=msdhcp earliest=11/02/2012:23:00:00 latest=11/03/2012:00:23:00 [search sourcetype=pan:traffic src_translated_port=##### src_translated_ip=###.###.##.## earliest=11/02/2012:23:00:00 latest=11/03/2012:00:23:00 | return 100 src_ip] | return 100 MAC]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;return takes the subsearch results, picks out the specified field (src_ip or MAC) and builds an OR'd chain of up to 100 or however many you like matches, which then get applied to the outer search as a filter. In order for this to work nicely you need to extract the MAC as a field in the campusmgr sourcetype... which probably is a good idea on its own.&lt;/P&gt;</description>
      <pubDate>Mon, 11 Mar 2013 21:20:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-Searching-for-matching-fields-within-multiple-source/m-p/57466#M11222</guid>
      <dc:creator>martin_mueller</dc:creator>
      <dc:date>2013-03-11T21:20:25Z</dc:date>
    </item>
    <item>
      <title>Re: Problem: Searching for matching fields within multiple source types</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-Searching-for-matching-fields-within-multiple-source/m-p/57467#M11223</link>
      <description>&lt;P&gt;Note that you can leave out the time specifiers (earliest/latest) since you're using the same ones in all searches. Just specify the time using the time dropdown or the earliest/latest flags/parameters on the CLI or API, rather than directly in the query, and all searches and subsearches will use that time range.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Mar 2013 00:47:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-Searching-for-matching-fields-within-multiple-source/m-p/57467#M11223</guid>
      <dc:creator>gkanapathy</dc:creator>
      <dc:date>2013-03-12T00:47:21Z</dc:date>
    </item>
  </channel>
</rss>

