<?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 create an eval column in a table that says &amp;quot;match&amp;quot; or &amp;quot;no match&amp;quot; if the value  of all columns is the same/or not for each row? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-an-eval-column-in-a-table-that-says-quot-match/m-p/399857#M115892</link>
    <description>&lt;P&gt;@samiksha86, based on the sample data provided try the following run anywhere search. Command from &lt;CODE&gt;makeresults&lt;/CODE&gt; till &lt;CODE&gt;| table test host1 host2 host3&lt;/CODE&gt; generates the sample data as per the question.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;|  makeresults
|  eval data="test1 x1 x1 x1;test2 y1 y2 y1;test3 z1 z2 z3"
|  makemv data delim=";"
|  mvexpand data
|  makemv data delim=" "
|  eval test=mvindex(data,0),host1=mvindex(data,1),host2=mvindex(data,2),host3=mvindex(data,3)
|  table test host1 host2 host3
|  eval temp=host1.",".host2.",".host3
|  makemv temp delim=","
|  eval temp=mvdedup(temp), matchCount=mvcount(temp), temp=if(matchCount=1,"Matched","Not Matched")
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Wed, 16 May 2018 10:20:46 GMT</pubDate>
    <dc:creator>niketn</dc:creator>
    <dc:date>2018-05-16T10:20:46Z</dc:date>
    <item>
      <title>How to create an eval column in a table that says "match" or "no match" if the value  of all columns is the same/or not for each row?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-an-eval-column-in-a-table-that-says-quot-match/m-p/399856#M115891</link>
      <description>&lt;PRE&gt;&lt;CODE&gt;test    host1   host2   host3   temp
test1   x1  x1  x1  Match
test2   y1  y2  y1  No match
test3   z1  z1  z3  No match
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 16 May 2018 06:39:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-an-eval-column-in-a-table-that-says-quot-match/m-p/399856#M115891</guid>
      <dc:creator>samiksha86</dc:creator>
      <dc:date>2018-05-16T06:39:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to create an eval column in a table that says "match" or "no match" if the value  of all columns is the same/or not for each row?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-an-eval-column-in-a-table-that-says-quot-match/m-p/399857#M115892</link>
      <description>&lt;P&gt;@samiksha86, based on the sample data provided try the following run anywhere search. Command from &lt;CODE&gt;makeresults&lt;/CODE&gt; till &lt;CODE&gt;| table test host1 host2 host3&lt;/CODE&gt; generates the sample data as per the question.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;|  makeresults
|  eval data="test1 x1 x1 x1;test2 y1 y2 y1;test3 z1 z2 z3"
|  makemv data delim=";"
|  mvexpand data
|  makemv data delim=" "
|  eval test=mvindex(data,0),host1=mvindex(data,1),host2=mvindex(data,2),host3=mvindex(data,3)
|  table test host1 host2 host3
|  eval temp=host1.",".host2.",".host3
|  makemv temp delim=","
|  eval temp=mvdedup(temp), matchCount=mvcount(temp), temp=if(matchCount=1,"Matched","Not Matched")
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 16 May 2018 10:20:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-an-eval-column-in-a-table-that-says-quot-match/m-p/399857#M115892</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2018-05-16T10:20:46Z</dc:date>
    </item>
    <item>
      <title>Re: How to create an eval column in a table that says "match" or "no match" if the value  of all columns is the same/or not for each row?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-an-eval-column-in-a-table-that-says-quot-match/m-p/399858#M115893</link>
      <description>&lt;P&gt;@niketnilay, what if the the values i.e. x1,x2y1,z1,etc are subject to changes and we have to compare then.&lt;BR /&gt;
How to compare in that scenario?&lt;/P&gt;</description>
      <pubDate>Thu, 26 Jul 2018 07:14:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-an-eval-column-in-a-table-that-says-quot-match/m-p/399858#M115893</guid>
      <dc:creator>abhi04</dc:creator>
      <dc:date>2018-07-26T07:14:18Z</dc:date>
    </item>
  </channel>
</rss>

