<?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: Searching multiple lookup tables in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29777#M6019</link>
    <description>&lt;P&gt;Awesome, thank you. I think the time-based lookup is what I'm looking for. I had some luck with the append=t flag as well. Thanks for your help! &lt;span class="lia-unicode-emoji" title=":grinning_face_with_smiling_eyes:"&gt;😄&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 10 May 2013 17:43:42 GMT</pubDate>
    <dc:creator>deadbits</dc:creator>
    <dc:date>2013-05-10T17:43:42Z</dc:date>
    <item>
      <title>Is there a way to search multiple lookup tables and do a stats count by X across all the tables within the same search?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29775#M6017</link>
      <description>&lt;P&gt;I am having some trouble performing a search across multiple lookup tables. I have several csv's as lookup tables (let's say table1.csv, table2.csv, table3.csv), all of which have the same field names with different data. I am trying to get a trending view of this data over time - as each lookup table covers one week's worth of data.&lt;/P&gt;
&lt;P&gt;Q: Is there a way to search multiple lookup tables and do a stats count by X across all the tables within the same search?&lt;/P&gt;
&lt;P&gt;A search for an individual table works fine. for example: |inputlookup table2.csv | stats count by field1&lt;/P&gt;
&lt;P&gt;a few of the searches I've tried are:&lt;BR /&gt;search one: [ | inputlookup table1.csv | stats count by field1 ] [ |inputlookup table2.csv | stats count by field1]&lt;BR /&gt;search two: |inputlookup table1.csv |inputlookup table2.csv | stats count by field1&lt;/P&gt;
&lt;P&gt;Am I going about this the complete wrong way or is what I'm trying to do simply not possible? Any help at all would be greatly appreciated!&lt;/P&gt;</description>
      <pubDate>Thu, 30 Mar 2023 15:28:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29775#M6017</guid>
      <dc:creator>deadbits</dc:creator>
      <dc:date>2023-03-30T15:28:20Z</dc:date>
    </item>
    <item>
      <title>Re: Searching multiple lookup tables</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29776#M6018</link>
      <description>&lt;P&gt;For the question as asked, something like this might work for you:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| inputlookup table1.csv | inputlookup append=t table2.csv | inputlookup append=t table3.csv | stats count by field1
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;However, you probably want to differentiate between the lookups, which you could do by having a second field (&lt;CODE&gt;lookup_name&lt;/CODE&gt;) like so:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| inputlookup table1.csv | inputlookup append=t table2.csv | inputlookup append=t table3.csv | stats count by field1 lookup_name
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Depending on your use case you may want to use a &lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0.2/Knowledge/Usefieldlookupstoaddinformationtoyourevents"&gt;time-based lookup&lt;/A&gt; combining all of the results.&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2013 08:36:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29776#M6018</guid>
      <dc:creator>dart</dc:creator>
      <dc:date>2013-05-10T08:36:48Z</dc:date>
    </item>
    <item>
      <title>Re: Searching multiple lookup tables</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29777#M6019</link>
      <description>&lt;P&gt;Awesome, thank you. I think the time-based lookup is what I'm looking for. I had some luck with the append=t flag as well. Thanks for your help! &lt;span class="lia-unicode-emoji" title=":grinning_face_with_smiling_eyes:"&gt;😄&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2013 17:43:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29777#M6019</guid>
      <dc:creator>deadbits</dc:creator>
      <dc:date>2013-05-10T17:43:42Z</dc:date>
    </item>
    <item>
      <title>Re: Searching multiple lookup tables</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29778#M6020</link>
      <description>&lt;P&gt;Thanks @dart this is awesome! How about this one:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| inputlookup table1.csv 
| append 
    [| inputlookup table2.csv]
    [| inputlookup table3.csv] 
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 22 Nov 2018 01:15:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29778#M6020</guid>
      <dc:creator>ipark_splunk</dc:creator>
      <dc:date>2018-11-22T01:15:04Z</dc:date>
    </item>
    <item>
      <title>Re: Searching multiple lookup tables</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29779#M6021</link>
      <description>&lt;P&gt;Say I have two lookup table1.csv and table2.csv and both has different fields. Now I want to include table1.csv but exclude results from msin search for column present on table 2.csv. how to do that&lt;/P&gt;</description>
      <pubDate>Tue, 14 Apr 2020 12:40:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29779#M6021</guid>
      <dc:creator>ksharma7</dc:creator>
      <dc:date>2020-04-14T12:40:34Z</dc:date>
    </item>
    <item>
      <title>Re: Searching multiple lookup tables</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29780#M6022</link>
      <description>&lt;P&gt;@ksharma7, This question is nearly 7 years old with an accepted answer.  Please post a new question describing your problem.&lt;/P&gt;</description>
      <pubDate>Tue, 14 Apr 2020 13:21:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/29780#M6022</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2020-04-14T13:21:31Z</dc:date>
    </item>
    <item>
      <title>Re: Searching multiple lookup tables</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/636730#M221131</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/970"&gt;@dart&lt;/a&gt;&amp;nbsp;&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/38016"&gt;@deadbits&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/57969"&gt;@ksharma7&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/151308"&gt;@ipark_splunk&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;1 Question:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;whatever example you shared thats great and working but what about multiple lookups if i wanted to search , for example if i am having 20 lookups like table1.csv to table20.csv with different name , Actually we can do appending for each of one, need your help here.&lt;/P&gt;&lt;P&gt;2 Question:&lt;/P&gt;&lt;P&gt;whatever result we are receiving in that i wanted to add lookup name as well because my all lookups are having different name with different name.&lt;BR /&gt;&lt;BR /&gt;Could you please help me on this ?&lt;/P&gt;</description>
      <pubDate>Thu, 30 Mar 2023 17:44:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Is-there-a-way-to-search-multiple-lookup-tables-and-do-a-stats/m-p/636730#M221131</guid>
      <dc:creator>asharma737</dc:creator>
      <dc:date>2023-03-30T17:44:57Z</dc:date>
    </item>
  </channel>
</rss>

