<?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 request comparison in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571004#M198973</link>
    <description>&lt;P&gt;Hello. How can two files be compared for identity ?&lt;/P&gt;&lt;P&gt;file1.csv:&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="50%"&gt;username&lt;/TD&gt;&lt;TD width="50%"&gt;id_user&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;Jonh&lt;/TD&gt;&lt;TD width="50%"&gt;123&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;file2.csv&amp;nbsp;&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="50%"&gt;username&lt;/TD&gt;&lt;TD width="50%"&gt;id_user&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;Jonh&lt;/TD&gt;&lt;TD width="50%"&gt;124&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How to write a request correctly.&amp;nbsp;To check if id_user is identical for one user in different files. Compare two files with the same ID or not&lt;/P&gt;&lt;P&gt;if file1.csv.id_user != file2.csv.id_user&amp;nbsp;&lt;/P&gt;&lt;P&gt;There was a message that the id is different&lt;/P&gt;</description>
    <pubDate>Thu, 14 Oct 2021 14:47:11 GMT</pubDate>
    <dc:creator>gitingua</dc:creator>
    <dc:date>2021-10-14T14:47:11Z</dc:date>
    <item>
      <title>request comparison</title>
      <link>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571004#M198973</link>
      <description>&lt;P&gt;Hello. How can two files be compared for identity ?&lt;/P&gt;&lt;P&gt;file1.csv:&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="50%"&gt;username&lt;/TD&gt;&lt;TD width="50%"&gt;id_user&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;Jonh&lt;/TD&gt;&lt;TD width="50%"&gt;123&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;file2.csv&amp;nbsp;&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="50%"&gt;username&lt;/TD&gt;&lt;TD width="50%"&gt;id_user&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;Jonh&lt;/TD&gt;&lt;TD width="50%"&gt;124&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How to write a request correctly.&amp;nbsp;To check if id_user is identical for one user in different files. Compare two files with the same ID or not&lt;/P&gt;&lt;P&gt;if file1.csv.id_user != file2.csv.id_user&amp;nbsp;&lt;/P&gt;&lt;P&gt;There was a message that the id is different&lt;/P&gt;</description>
      <pubDate>Thu, 14 Oct 2021 14:47:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571004#M198973</guid>
      <dc:creator>gitingua</dc:creator>
      <dc:date>2021-10-14T14:47:11Z</dc:date>
    </item>
    <item>
      <title>Re: request comparison</title>
      <link>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571015#M198977</link>
      <description>&lt;LI-CODE lang="markup"&gt;| inputlookup file1.csv
| rename id_user as id_user1
| append [| inputlookup file2.csv]
| stats values(id_user1) as id_user1 values(id_user) as id_user2 by username
| where id_user1 != id_user2&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 14 Oct 2021 16:03:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571015#M198977</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2021-10-14T16:03:11Z</dc:date>
    </item>
    <item>
      <title>Re: request comparison</title>
      <link>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571230#M199042</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But how to make the check on two attributes.&lt;/P&gt;&lt;P&gt;but how to do a check on two attributes. if both are not alike&lt;BR /&gt;&lt;BR /&gt;when I write a check for two attributes using "or". that is, one thing is similar, nothing comes out of my output. And if both are not alike, then everything turns out right&lt;BR /&gt;&lt;BR /&gt;If&amp;nbsp;&lt;/P&gt;&lt;P&gt;file1.csv&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;user&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;id_user&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;group&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;John&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;123&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;56&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;file2.csv&amp;nbsp;&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;user&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;id_user&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;group&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;John&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;124&lt;/TD&gt;&lt;TD width="33.333333333333336%" height="25px"&gt;56&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| inputlookup file1.csv
| rename id_user as id_user1
| rename group as group1
| append [| inputlookup file2.csv]
| stats values(id_user1) as id_user1 values(id_user) as id_user2 values(group1) as group1 values(group) as group2 by username
| where id_user1 != id_user2 or group1 != group2&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;output:&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="20%"&gt;user&lt;/TD&gt;&lt;TD width="20%"&gt;&amp;nbsp;id_user1&lt;/TD&gt;&lt;TD width="20%"&gt;&amp;nbsp;id_user2&lt;/TD&gt;&lt;TD width="20%"&gt;group1&lt;/TD&gt;&lt;TD width="20%"&gt;group2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="20%"&gt;John&lt;/TD&gt;&lt;TD width="20%"&gt;123&lt;/TD&gt;&lt;TD width="20%"&gt;124&lt;/TD&gt;&lt;TD width="20%"&gt;56&lt;/TD&gt;&lt;TD width="20%"&gt;56&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;but need:&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="25%"&gt;user&lt;/TD&gt;&lt;TD width="25%"&gt;id_user1&lt;/TD&gt;&lt;TD width="25%"&gt;id_user2&lt;/TD&gt;&lt;TD width="25%"&gt;group&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="25%"&gt;John&lt;/TD&gt;&lt;TD width="25%"&gt;123&lt;/TD&gt;&lt;TD width="25%"&gt;124&lt;/TD&gt;&lt;TD width="25%"&gt;56&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;</description>
      <pubDate>Sun, 17 Oct 2021 13:42:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571230#M199042</guid>
      <dc:creator>gitingua</dc:creator>
      <dc:date>2021-10-17T13:42:13Z</dc:date>
    </item>
    <item>
      <title>Re: request comparison</title>
      <link>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571231#M199043</link>
      <description>&lt;LI-CODE lang="markup"&gt;| makeresults
| eval user="John", id_user=123, group=56
| rename id_user as id_user1
| rename group as group1
| append 
    [| makeresults
    | eval user="John", id_user=124, group=56]
| stats values(id_user1) as id_user1 values(id_user) as id_user2 values(group1) as group1 values(group) as group2 by user
| where id_user1 != id_user2 or group1 != group2
| eval group=if(group1=group2,group1,null())
| eval group1=if(isnull(group),group1,null())
| eval group2=if(isnull(group),group2,null())&lt;/LI-CODE&gt;</description>
      <pubDate>Sun, 17 Oct 2021 14:09:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571231#M199043</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2021-10-17T14:09:27Z</dc:date>
    </item>
    <item>
      <title>Re: request comparison</title>
      <link>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571234#M199045</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/232899"&gt;@gitingua&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;What about the below solution,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;|  set diff 
    [| inputlookup file1.csv] 
    [| inputlookup file2.csv]
| stats values(group), values(id_user) by user&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sid&lt;/P&gt;</description>
      <pubDate>Sun, 17 Oct 2021 17:26:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571234#M199045</guid>
      <dc:creator>techiesid</dc:creator>
      <dc:date>2021-10-17T17:26:25Z</dc:date>
    </item>
    <item>
      <title>Re: request comparison</title>
      <link>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571235#M199046</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;Thanks my friend.&amp;nbsp;but can you tell me how to correctly pull data from files using inputlookup?&amp;nbsp;Thanks a lot !!&lt;/P&gt;</description>
      <pubDate>Sun, 17 Oct 2021 17:27:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571235#M199046</guid>
      <dc:creator>gitingua</dc:creator>
      <dc:date>2021-10-17T17:27:39Z</dc:date>
    </item>
    <item>
      <title>Re: request comparison</title>
      <link>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571244#M199048</link>
      <description>&lt;LI-CODE lang="markup"&gt;| inputlookup file1.csv
| rename id_user as id_user1
| rename group as group1
| append [| inputlookup file2.csv]
| stats values(id_user1) as id_user1 values(id_user) as id_user2 values(group1) as group1 values(group) as group2 by username
| where id_user1 != id_user2 or group1 != group2
| eval group=if(group1=group2,group1,null())
| eval group1=if(isnull(group),group1,null())
| eval group2=if(isnull(group),group2,null())&lt;/LI-CODE&gt;</description>
      <pubDate>Sun, 17 Oct 2021 21:15:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571244#M199048</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2021-10-17T21:15:08Z</dc:date>
    </item>
    <item>
      <title>Re: request comparison</title>
      <link>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571247#M199050</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;You are the best!! Thanks&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 17 Oct 2021 21:45:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/request-comparison/m-p/571247#M199050</guid>
      <dc:creator>gitingua</dc:creator>
      <dc:date>2021-10-17T21:45:29Z</dc:date>
    </item>
  </channel>
</rss>

