<?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: Using variables with IN and LIKE functions in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581753#M202666</link>
    <description>&lt;P&gt;Inner searches are executed before outer searches so this is unlikely to work! Try finding a way to invert the searches&lt;/P&gt;</description>
    <pubDate>Wed, 19 Jan 2022 21:33:33 GMT</pubDate>
    <dc:creator>ITWhisperer</dc:creator>
    <dc:date>2022-01-19T21:33:33Z</dc:date>
    <item>
      <title>Using variables with IN and LIKE functions</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581713#M202650</link>
      <description>&lt;P&gt;I am using Splunk Enterprise V8.2.3.2. I am trying to alert when a scheduled search becomes disabled. The problem is that I have four systems using the same app but with different searches enabled and disabled for each of the systems. I need to dynamically determine which system the alert is running on and get the corresponding list of searches that are supposed to be enabled from a lookup table.&lt;/P&gt;&lt;P&gt;I have done that. Now I need to see if the disabled search name matches one of the search names in the lookup table list. List is like:&lt;/P&gt;&lt;P&gt;Searches that should be enabled(fieldname searches):&amp;nbsp; apple tart,blueberry pie,carrot cake,cupcake&lt;/P&gt;&lt;P&gt;Search found to be disabled(fieldname disabled): carrot cake&lt;/P&gt;&lt;P&gt;I would like to do something like:&lt;/P&gt;&lt;P&gt;eval failed=if(in(disabled,searches),"Failed","Passed")&lt;/P&gt;&lt;P&gt;where disabled in(searches)&lt;/P&gt;&lt;P&gt;or,&amp;nbsp; search disabled IN searches&lt;/P&gt;&lt;P&gt;However, none of these approaches have worked. Any advice? Thanks in advance.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 19 Jan 2022 17:58:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581713#M202650</guid>
      <dc:creator>drezanka</dc:creator>
      <dc:date>2022-01-19T17:58:27Z</dc:date>
    </item>
    <item>
      <title>Re: Using variables with IN and LIKE functions</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581719#M202652</link>
      <description>&lt;P&gt;Have you tried it the other way around&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eval failed=if(len(disabled)&amp;gt;0 AND match(searches,disabled),"Failed","Passed")&lt;/LI-CODE&gt;</description>
      <pubDate>Wed, 19 Jan 2022 18:59:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581719#M202652</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-01-19T18:59:01Z</dc:date>
    </item>
    <item>
      <title>Re: Using variables with IN and LIKE functions</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581726#M202656</link>
      <description>&lt;P&gt;It's really a chicken and egg problem. I am trying to use the result of an outer search in an inner search. Working on alternatives.&lt;/P&gt;</description>
      <pubDate>Wed, 19 Jan 2022 20:03:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581726#M202656</guid>
      <dc:creator>drezanka</dc:creator>
      <dc:date>2022-01-19T20:03:58Z</dc:date>
    </item>
    <item>
      <title>Re: Using variables with IN and LIKE functions</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581753#M202666</link>
      <description>&lt;P&gt;Inner searches are executed before outer searches so this is unlikely to work! Try finding a way to invert the searches&lt;/P&gt;</description>
      <pubDate>Wed, 19 Jan 2022 21:33:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581753#M202666</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-01-19T21:33:33Z</dc:date>
    </item>
    <item>
      <title>Re: Using variables with IN and LIKE functions</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581770#M202670</link>
      <description>&lt;P&gt;I was able to use split() to compare two variables rather than having to have a distinct list defined. Solved&lt;/P&gt;</description>
      <pubDate>Wed, 19 Jan 2022 22:12:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Using-variables-with-IN-and-LIKE-functions/m-p/581770#M202670</guid>
      <dc:creator>drezanka</dc:creator>
      <dc:date>2022-01-19T22:12:14Z</dc:date>
    </item>
  </channel>
</rss>

