<?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: how to make lookup fields as static and the results as dynamic from the search query in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338714#M100442</link>
    <description>&lt;P&gt;Hi Kwip,&lt;/P&gt;

&lt;P&gt;Can you try this:&lt;BR /&gt;
index=XXX sourcetype=yyyy status=* job=* &lt;BR /&gt;
 | lookup dummy.csv job OUTPUT Category&lt;BR /&gt;
 | stats latest(status) as CurrentStatus values(StartTime) values(EndTime) values(Category) AS Category by job &lt;/P&gt;</description>
    <pubDate>Tue, 17 Apr 2018 06:42:59 GMT</pubDate>
    <dc:creator>deepashri_123</dc:creator>
    <dc:date>2018-04-17T06:42:59Z</dc:date>
    <item>
      <title>how to make lookup fields as static and the results as dynamic from the search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338707#M100435</link>
      <description>&lt;P&gt;Hi&lt;BR /&gt;
I am having some of the fields in my lookup file (csv file). And I want list down the lookup fields along with the search query result.&lt;/P&gt;

&lt;P&gt;But I want my lookup fields as static and search results as dynamic.&lt;/P&gt;

&lt;P&gt;Say Example,&lt;BR /&gt;
I am having field A B C in my lookup file, and generating  D and E from the search query result. In my dashboard/form panel A, B and C fields should be always visible. Whereas D and E are based on the search result.&lt;/P&gt;

&lt;P&gt;My sample query,&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=XXX sourcetype=yyyy status=* job=* 
| lookup dummy.csv Category
| stats latest(status) as CurrentStatus by Category job StartTime EndTime
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;In the above sample, Category is from lookup table job is the matching point for both lookup and search query. starttime and endtime is from the search result.&lt;/P&gt;

&lt;P&gt;So in my dashboard Category and job values should be visible always, other field values may get updated as per the search query.&lt;/P&gt;</description>
      <pubDate>Tue, 17 Apr 2018 05:22:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338707#M100435</guid>
      <dc:creator>Kwip</dc:creator>
      <dc:date>2018-04-17T05:22:25Z</dc:date>
    </item>
    <item>
      <title>Re: how to make lookup fields as static and the results as dynamic from the search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338708#M100436</link>
      <description>&lt;P&gt;Can you try:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; index=XXX sourcetype=yyyy status=* job=* 
 | lookup job  dummy.csv Category
 | stats latest(status) as CurrentStatus list (StartTime) list(EndTime)by Category job 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Also you can try using inputlookup command.&lt;/P&gt;</description>
      <pubDate>Tue, 17 Apr 2018 05:32:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338708#M100436</guid>
      <dc:creator>p_gurav</dc:creator>
      <dc:date>2018-04-17T05:32:43Z</dc:date>
    </item>
    <item>
      <title>Re: how to make lookup fields as static and the results as dynamic from the search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338709#M100437</link>
      <description>&lt;P&gt;@p_gurav &lt;BR /&gt;
Thanks for your response!&lt;/P&gt;

&lt;P&gt;In this case, I am getting error like lookup name "job" does not exits. It is considering job as lookup name.&lt;/P&gt;</description>
      <pubDate>Tue, 17 Apr 2018 05:39:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338709#M100437</guid>
      <dc:creator>Kwip</dc:creator>
      <dc:date>2018-04-17T05:39:41Z</dc:date>
    </item>
    <item>
      <title>Re: how to make lookup fields as static and the results as dynamic from the search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338710#M100438</link>
      <description>&lt;P&gt;Extremely sorry. Try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;  index=XXX sourcetype=yyyy status=* job=* 
  | lookup  dummy.csv job OUTPUT Category
  | stats latest(status) as CurrentStatus list (StartTime) list(EndTime)by Category job 
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 17 Apr 2018 05:42:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338710#M100438</guid>
      <dc:creator>p_gurav</dc:creator>
      <dc:date>2018-04-17T05:42:20Z</dc:date>
    </item>
    <item>
      <title>Re: how to make lookup fields as static and the results as dynamic from the search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338711#M100439</link>
      <description>&lt;P&gt;Again it is listing down the values which are returned from the search query. &lt;/P&gt;

&lt;P&gt;I need Category and job values from my lookup table to be in the table as static irrespective of the search result. &lt;/P&gt;

&lt;P&gt;Say example I am having 10 values for job and equivalent category values in my look up file. From the search I am getting the status, StartTime, EndTime fields and its values.&lt;/P&gt;

&lt;P&gt;There are scenarios, I will only get status, Startime and endtime only for 5 job and category values from my search result. In such cases my output table will have only 5 rows for which the search given results.&lt;/P&gt;

&lt;P&gt;But I want to create like, My table should always show all the values(10 values) of Category and job, Other fields values should get updated  upon the search result. So in the above example, my resulted table should be like. &lt;/P&gt;

&lt;P&gt;Job Category Status StatTime EndTime&lt;BR /&gt;
1     -a              -RU        - 9              -NC&lt;BR /&gt;
2     -s              -SU         -5               -11&lt;BR /&gt;
3    -d               -FA         -4                 NA&lt;BR /&gt;
4     -f&lt;BR /&gt;
5     -e&lt;BR /&gt;
6     -q&lt;BR /&gt;
7    -v                -SU          -5               -6&lt;BR /&gt;
8    -n               -RU           -4               NC&lt;BR /&gt;
9    -x&lt;BR /&gt;
10   -l&lt;/P&gt;</description>
      <pubDate>Tue, 17 Apr 2018 06:22:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338711#M100439</guid>
      <dc:creator>Kwip</dc:creator>
      <dc:date>2018-04-17T06:22:42Z</dc:date>
    </item>
    <item>
      <title>Re: how to make lookup fields as static and the results as dynamic from the search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338712#M100440</link>
      <description>&lt;P&gt;Hey@Kwip,&lt;/P&gt;

&lt;P&gt;Can you try something like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=XXX sourcetype=yyyy status=* job=* 
| lookup dummy.csv job OUTPUT Category
| search Category="*"
| stats latest(status) as CurrentStatus values(StartTime) values(EndTime) by Category,job 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Let me know if this helps!!&lt;/P&gt;</description>
      <pubDate>Tue, 17 Apr 2018 06:25:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338712#M100440</guid>
      <dc:creator>deepashri_123</dc:creator>
      <dc:date>2018-04-17T06:25:53Z</dc:date>
    </item>
    <item>
      <title>Re: how to make lookup fields as static and the results as dynamic from the search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338713#M100441</link>
      <description>&lt;P&gt;Hi @deepashri_123&lt;BR /&gt;
Thanks for your response. It is giving the same result what I have already.&lt;/P&gt;</description>
      <pubDate>Tue, 17 Apr 2018 06:30:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338713#M100441</guid>
      <dc:creator>Kwip</dc:creator>
      <dc:date>2018-04-17T06:30:43Z</dc:date>
    </item>
    <item>
      <title>Re: how to make lookup fields as static and the results as dynamic from the search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338714#M100442</link>
      <description>&lt;P&gt;Hi Kwip,&lt;/P&gt;

&lt;P&gt;Can you try this:&lt;BR /&gt;
index=XXX sourcetype=yyyy status=* job=* &lt;BR /&gt;
 | lookup dummy.csv job OUTPUT Category&lt;BR /&gt;
 | stats latest(status) as CurrentStatus values(StartTime) values(EndTime) values(Category) AS Category by job &lt;/P&gt;</description>
      <pubDate>Tue, 17 Apr 2018 06:42:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338714#M100442</guid>
      <dc:creator>deepashri_123</dc:creator>
      <dc:date>2018-04-17T06:42:59Z</dc:date>
    </item>
    <item>
      <title>Re: how to make lookup fields as static and the results as dynamic from the search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338715#M100443</link>
      <description>&lt;P&gt;Got the answer from this post.&lt;/P&gt;

&lt;P&gt;&lt;A href="https://answers.splunk.com/answers/208671/how-to-create-a-table-with-a-static-column-a-and-d.html"&gt;https://answers.splunk.com/answers/208671/how-to-create-a-table-with-a-static-column-a-and-d.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Apr 2018 02:17:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-make-lookup-fields-as-static-and-the-results-as-dynamic/m-p/338715#M100443</guid>
      <dc:creator>Kwip</dc:creator>
      <dc:date>2018-04-18T02:17:31Z</dc:date>
    </item>
  </channel>
</rss>

