<?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 compare two inputlook kv columns? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644205#M223138</link>
    <description>&lt;P&gt;My mistake. &amp;nbsp;File1 and File2 needs to be quoted.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| inputlookup File1 ``` OUTPUT A B C ```
| eval kv = "File1"
| append
    [| inputlookup File2 ``` OUTPUT A B C ```
    | eval kv = "File2"]
| stats dc(kv) as lookupcount values(kv) as lookup by A B C
| where lookupcount = 1 AND kv == "File1"&lt;/LI-CODE&gt;</description>
    <pubDate>Tue, 23 May 2023 05:33:46 GMT</pubDate>
    <dc:creator>yuanliu</dc:creator>
    <dc:date>2023-05-23T05:33:46Z</dc:date>
    <item>
      <title>How to compare two inputlook kv columns?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/643730#M223001</link>
      <description>&lt;P&gt;Hi There,&amp;nbsp;&lt;BR /&gt;we have two inputlook kv (File1 and File2)&amp;nbsp; files and I want to compare 3 columns (AvsA, BvsB, CvsC) between each file and display the result where we clouldn't find any value in all the 3 columns( like non of the comparison written any value I mean blank).&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Eg. File1 has Column A which contains roll numbers, Column B contains the Name and Column C contains the Registration number. File2 has the similar columns therefore we need to compare the information&amp;nbsp;(AvsA, BvsB, CvsC) and find out where we have blanks (like there were no results for all the comparison AvsA, BvsB and CvsC) and report them in a table unique once.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 18 May 2023 12:18:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/643730#M223001</guid>
      <dc:creator>akshaycloud11</dc:creator>
      <dc:date>2023-05-18T12:18:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare two inputlook kv columns?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/643798#M223027</link>
      <description>&lt;P&gt;By "comparison" I assume you mean an equality test, where a false value is considered "blank". &amp;nbsp;If this is correct, &lt;A href="https://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Aggregatefunctions#distinct_count.28.26lt.3Bvalue.26gt.3B.29_or_dc.28.26lt.3Bvalue.26gt.3B.29" target="_blank" rel="noopener"&gt;distinct_count&lt;/A&gt;, or dc, is your answer. &amp;nbsp;This is something you can try&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| inputlookup File1 ``` OUTPUT A B C ```
| eval kv = File1
| append
    [| inputlookup File2 ``` OUTPUT A B C ```
    | eval kv = File2]
| stats dc(kv) as lookupcount values(kv) as lookup by A B C
| where lookupcount = 1&lt;/LI-CODE&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;</description>
      <pubDate>Thu, 18 May 2023 15:07:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/643798#M223027</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2023-05-18T15:07:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare two inputlook kv columns?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644113#M223120</link>
      <description>&lt;P&gt;Hi There,&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Below are the issues I am facing while trying the solution&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;1. dc(kv) isn't working in lookupfile. Tried multiple ways and looks like it isn't supporting the lookupfile.&amp;nbsp;&lt;BR /&gt;2. We need to compare File 1 data(it has 10K records) with File2(it has 30K) records and figure out the data which is&amp;nbsp; present in File1 and not present in File 2 based on lookup by 3 columns (A,B,C) and report the unique only records. We need to report File1 missing data in File2.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 22 May 2023 10:28:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644113#M223120</guid>
      <dc:creator>akshaycloud11</dc:creator>
      <dc:date>2023-05-22T10:28:22Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare two inputlook kv columns?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644205#M223138</link>
      <description>&lt;P&gt;My mistake. &amp;nbsp;File1 and File2 needs to be quoted.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| inputlookup File1 ``` OUTPUT A B C ```
| eval kv = "File1"
| append
    [| inputlookup File2 ``` OUTPUT A B C ```
    | eval kv = "File2"]
| stats dc(kv) as lookupcount values(kv) as lookup by A B C
| where lookupcount = 1 AND kv == "File1"&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 23 May 2023 05:33:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644205#M223138</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2023-05-23T05:33:46Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare two inputlook kv columns?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644243#M223157</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/33901"&gt;@yuanliu&lt;/a&gt;&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;when we run the query, the second part of the where condition( kv == "File1") doesn't return any results.&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;| where lookupcount = 1 AND kv == "File1"&lt;/PRE&gt;&lt;P&gt;where condition works for lookupcount =1 and shows the File2 records but we need to find the results of File1 (unique values only). Kindly help.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 23 May 2023 11:26:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644243#M223157</guid>
      <dc:creator>akshaycloud11</dc:creator>
      <dc:date>2023-05-23T11:26:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare two inputlook kv columns?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644255#M223160</link>
      <description>&lt;P&gt;I also want to understand what you mean by ```OUTPUT A B C`` because inputlookup doesn't support OUTPUT.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 May 2023 13:26:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644255#M223160</guid>
      <dc:creator>akshaycloud11</dc:creator>
      <dc:date>2023-05-23T13:26:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare two inputlook kv columns?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644280#M223169</link>
      <description>&lt;P&gt;You are correct that inputlookup command doesn't have an "OUTPUT" option; the tree back ticks ("`") opens a comment that is closed by three back ticks. &amp;nbsp;These comments are meant to highlight that I expect both output from File1 and from File2 to contain A, B, and C.&lt;/P&gt;&lt;P&gt;Now, if the condition&amp;nbsp;lookupcount = 1 AND kv == "File1" gives you no results but&amp;nbsp;lookupcount = 1 AND kv == "File2" returns some thing, that logically means that every combination of A, B, and C that appears in File1 is found in File2, whereas there are some unique combinations in File2. &amp;nbsp;One way to examine data quickly is to run&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| inputlookup File1 ``` OUTPUT A B C ```
| eval kv = "File1"
| append
    [| inputlookup File2 ``` OUTPUT A B C ```
    | eval kv = "File2"]
| stats dc(kv) as lookupcount values(kv) as lookup by A B C
| sort lookupcount&lt;/LI-CODE&gt;&lt;P&gt;You can see which lookup table have count of one for which combinations of A, B, C.&lt;/P&gt;</description>
      <pubDate>Tue, 23 May 2023 16:08:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/644280#M223169</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2023-05-23T16:08:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare two inputlook kv columns?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/645775#M223587</link>
      <description>&lt;P&gt;The query is giving false results ( I mean, the query is reporting the data which is present in File 2)&lt;BR /&gt;let me explain the problem one more time.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;File 1&lt;/P&gt;&lt;TABLE border="1" width="100.00112663361875%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="10%"&gt;&lt;SPAN&gt;Row#&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD width="10%" height="47px"&gt;&lt;SPAN&gt;roll numbers&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD width="20%" height="47px"&gt;&lt;SPAN&gt;Name&amp;nbsp;&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD width="20%" height="47px"&gt;Registration #&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="10%"&gt;1&lt;/TD&gt;&lt;TD width="10%" height="25px"&gt;5&lt;/TD&gt;&lt;TD width="20%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="20%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="10%"&gt;2&lt;/TD&gt;&lt;TD width="10%" height="25px"&gt;7&lt;/TD&gt;&lt;TD width="20%" height="25px"&gt;Ajay&lt;/TD&gt;&lt;TD width="20%" height="25px"&gt;999&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="10%"&gt;3&lt;/TD&gt;&lt;TD width="10%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="20%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="20%" height="25px"&gt;123&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="10%"&gt;4&lt;/TD&gt;&lt;TD width="10%" height="25px"&gt;10&lt;/TD&gt;&lt;TD width="20%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="20%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="10%"&gt;5&lt;/TD&gt;&lt;TD width="10%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="20%" height="25px"&gt;Vijay&lt;/TD&gt;&lt;TD width="20%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;BR /&gt;File2&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="12.5%" height="25px"&gt;Row#&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;Class&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;&lt;SPAN&gt;roll numbers&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;Section&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;Name&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;Registration #&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="12.5%" height="25px"&gt;1&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;V&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;2&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;A&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;Aaron&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;565&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="12.5%" height="25px"&gt;2&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;VI&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;4&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;B&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;Michel&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;321&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="12.5%" height="25px"&gt;3&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;IV&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;3&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;D&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;Jeff&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;678&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="12.5%" height="25px"&gt;4&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;VIII&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;7&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;E&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;Ajay&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;999&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="12.5%" height="25px"&gt;5&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;X&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;8&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;H&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;Kumar&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;767&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="12.5%" height="25px"&gt;6&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;XII&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;10&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;F&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;098&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="12.5%" height="25px"&gt;7&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;XI&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;12&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;N&lt;/TD&gt;&lt;TD width="12.5%" height="25px"&gt;Evan&lt;/TD&gt;&lt;TD width="25%" height="25px"&gt;&amp;nbsp;345&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;now, I want to compare the following columns:&lt;BR /&gt;Roll numbers(File1) against Roll numbers(File2)&lt;BR /&gt;Name(File1) against the Name(File2)&lt;BR /&gt;Registration #(File1) against the Registration#(File2)&lt;BR /&gt;&lt;BR /&gt;if we find any one of the record File1 in File2 then we will not report that, I shall only report the record which we couldn't find by roll number/name/registration#&lt;BR /&gt;&lt;BR /&gt;Note - We have to compare FILE1 against FILE 2 and report the FILE1 missing records in File2&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Desired OUTPUT&amp;nbsp;&lt;/P&gt;&lt;TABLE border="1" width="100.00000000000001%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="16.666666666666668%"&gt;&lt;SPAN&gt;Row #&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD width="16.666666666666668%" height="25px"&gt;&lt;SPAN&gt;roll numbers&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;Name&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;Registration #&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="16.666666666666668%"&gt;1&lt;/TD&gt;&lt;TD width="16.666666666666668%" height="25px"&gt;5&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="16.666666666666668%"&gt;2&lt;/TD&gt;&lt;TD width="16.666666666666668%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;123&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="16.666666666666668%"&gt;3&lt;/TD&gt;&lt;TD width="16.666666666666668%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;Vijay&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Total 3 records not found (present in File1 and not present in File2)&lt;/P&gt;</description>
      <pubDate>Mon, 05 Jun 2023 13:48:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/645775#M223587</guid>
      <dc:creator>akshaycloud11</dc:creator>
      <dc:date>2023-06-05T13:48:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to compare two inputlook kv columns?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/645867#M223613</link>
      <description>&lt;P&gt;This should be a lesson for anyone asking question in this forum: Explain the raw data, describe important features such as blank or null values, which fields accompany which type of events, etc. &amp;nbsp;We could have saved a ton of time and energy had you&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;explained that some of your A, B, and C can be blank or null, as well as rules (logic) to deal with them, and&lt;/LI&gt;&lt;LI&gt;the fact that you are trying to exclude matching of ANY of A, B, or C, not all of A, B, and C.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;What may seem "obvious" to you cannot be obvious to volunteers who lack intimate knowledge about your data and use case.&lt;/P&gt;&lt;P&gt;If I take data from your last post, A -&amp;gt; Name, B -&amp;gt; Registration #, and C -&amp;gt; roll numbers, I see lots of them have a single blank character (" ") as value in both File 1 and File 2. &amp;nbsp;Do you count them as "found"? &amp;nbsp;Based on your desired output, you seem to deem them "not found" in File 2.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If&lt;/STRONG&gt; this interpretation is correct, &lt;STRONG&gt;and&lt;/STRONG&gt; &lt;STRONG&gt;if&lt;/STRONG&gt; your special repeating values are single blank character " ", the following should give you desired output:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| inputlookup File1
| eval kv = "File1"
| append
  [| inputlookup File2
  | eval kv = "File2"]
| eventstats dc(kv) as lookupcount values(kv) as lookup by Name
| where lookupcount == 1 OR Name == " "
| eventstats dc(kv) as lookupcount values(kv) as lookup by Registration__
| where lookupcount == 1 OR Registration__ == " "
| eventstats dc(kv) as lookupcount values(kv) as lookup by roll_numbers
| where (lookupcount == 1 OR roll_numbers == " ") AND lookup == "File1"&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To help visualize, the following is an emulation of the two inputlookup appends based on sample data you posted:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| makeresults
| eval _raw = "
Row#	roll numbers	Name 	Registration #
1	5	 	 
2	7	Ajay	999
3	 	 	123
4	10	 	 
5	 	Vijay	 "
| multikv
| rename Name_ as Name
| eval kv = "File1"
| fields - _time _raw linecount
| append
    [| makeresults
    | eval _raw ="
Row#	Class	roll numbers	Section	Name	Registration #
1	V	2	A	Aaron	565
2	VI	4	B	Michel	321
3	IV	3	D	Jeff	678
4	VIII	7	E	Ajay	999
5	X	8	H	Kumar	767
6	XII	10	F	 	098
7	XI	12	N	Evan	 345"
    | multikv
    | fields - _time _raw linecount
    | eval kv = "File2"]
``` the above simulates two inputlookups appended together ```&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can play with this emulation and compare with your actual inputlookups. &amp;nbsp;Put this emulation with cascaded eventstats-where from the above code, i.e.,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eventstats dc(kv) as lookupcount values(kv) as lookup by Name
| where lookupcount == 1 OR Name == " "
| eventstats dc(kv) as lookupcount values(kv) as lookup by Registration__
| where lookupcount == 1 OR Registration__ == " "
| eventstats dc(kv) as lookupcount values(kv) as lookup by roll_numbers
| where (lookupcount == 1 OR roll_numbers == " ") AND lookup == "File1"&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I get&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Class&lt;/TD&gt;&lt;TD&gt;Name&lt;/TD&gt;&lt;TD&gt;Registration__&lt;/TD&gt;&lt;TD&gt;Row_&lt;/TD&gt;&lt;TD&gt;Section&lt;/TD&gt;&lt;TD&gt;kv&lt;/TD&gt;&lt;TD&gt;lookup&lt;/TD&gt;&lt;TD&gt;lookupcount&lt;/TD&gt;&lt;TD&gt;roll_numbers&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;File1&lt;/TD&gt;&lt;TD&gt;File1&lt;/TD&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;5&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;123&lt;/TD&gt;&lt;TD&gt;3&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;File1&lt;/TD&gt;&lt;TD&gt;File1&lt;/TD&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;Vijay&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;5&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;TD&gt;File1&lt;/TD&gt;&lt;TD&gt;File1&lt;/TD&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;Hope this helps&lt;/P&gt;</description>
      <pubDate>Tue, 06 Jun 2023 07:53:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-compare-two-inputlook-kv-columns/m-p/645867#M223613</guid>
      <dc:creator>yuanliu</dc:creator>
      <dc:date>2023-06-06T07:53:55Z</dc:date>
    </item>
  </channel>
</rss>

