<?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 use a wildcard with a where clause? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122060#M32842</link>
    <description>&lt;P&gt;Hi alladin101,&lt;/P&gt;

&lt;P&gt;it's me again &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;Now I get it; no this is not the way you use &lt;CODE&gt;where&lt;/CODE&gt;. If you use &lt;CODE&gt;where&lt;/CODE&gt; you will compare two fields and their respective values. You would have to use &lt;CODE&gt;search&lt;/CODE&gt; because this will search using the value of the field.&lt;/P&gt;

&lt;P&gt;like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=whatever* sourcetype=server
 |rex field=CLIENT_VERSION "\'(?P.+)\'" 
 |table version
 |search version=*10_2*
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;hope this helps...&lt;/P&gt;

&lt;P&gt;cheers, MuS&lt;/P&gt;</description>
    <pubDate>Fri, 14 Nov 2014 08:21:27 GMT</pubDate>
    <dc:creator>MuS</dc:creator>
    <dc:date>2014-11-14T08:21:27Z</dc:date>
    <item>
      <title>How to use a wildcard with a where clause?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122059#M32841</link>
      <description>&lt;P&gt;Hi - I wish to use a wildcard in the where clause in the below query can someone help?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=whatever* sourcetype=server
|rex field=CLIENT_VERSION "\'(?P.+)\'" 
|table version
|where version=*10_2*
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;here the value in the version field is FS_10_2_17387/FS_10_2_12387/FS_10_2_17987&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 18:10:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122059#M32841</guid>
      <dc:creator>allladin101</dc:creator>
      <dc:date>2020-09-28T18:10:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a wildcard with a where clause?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122060#M32842</link>
      <description>&lt;P&gt;Hi alladin101,&lt;/P&gt;

&lt;P&gt;it's me again &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;Now I get it; no this is not the way you use &lt;CODE&gt;where&lt;/CODE&gt;. If you use &lt;CODE&gt;where&lt;/CODE&gt; you will compare two fields and their respective values. You would have to use &lt;CODE&gt;search&lt;/CODE&gt; because this will search using the value of the field.&lt;/P&gt;

&lt;P&gt;like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=whatever* sourcetype=server
 |rex field=CLIENT_VERSION "\'(?P.+)\'" 
 |table version
 |search version=*10_2*
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;hope this helps...&lt;/P&gt;

&lt;P&gt;cheers, MuS&lt;/P&gt;</description>
      <pubDate>Fri, 14 Nov 2014 08:21:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122060#M32842</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2014-11-14T08:21:27Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a wildcard with a where clause?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122061#M32843</link>
      <description>&lt;P&gt;Hi Mus,&lt;/P&gt;

&lt;P&gt;Thanks for the answer &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;can i use this as well?&lt;BR /&gt;
&lt;CODE&gt;|where like(version,"%FX_10_2%")&lt;BR /&gt;
&lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 18:10:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122061#M32843</guid>
      <dc:creator>allladin101</dc:creator>
      <dc:date>2020-09-28T18:10:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a wildcard with a where clause?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122062#M32844</link>
      <description>&lt;P&gt;yes, this should work as well&lt;/P&gt;</description>
      <pubDate>Fri, 14 Nov 2014 08:38:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122062#M32844</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2014-11-14T08:38:51Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a wildcard with a where clause?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122063#M32845</link>
      <description>&lt;P&gt;This just saved my life! Thanks!&lt;/P&gt;</description>
      <pubDate>Wed, 01 Feb 2017 16:31:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122063#M32845</guid>
      <dc:creator>LAcioffi</dc:creator>
      <dc:date>2017-02-01T16:31:51Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a wildcard with a where clause?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122064#M32846</link>
      <description>&lt;P&gt;FYI - the optimizer will combine this into &lt;CODE&gt;search(index=whatever* sourcetype=server version=*10_2*)&lt;/CODE&gt;, as if it was part of the original search query.&lt;/P&gt;</description>
      <pubDate>Tue, 07 Mar 2017 22:37:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122064#M32846</guid>
      <dc:creator>markbarber21</dc:creator>
      <dc:date>2017-03-07T22:37:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a wildcard with a where clause?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122065#M32847</link>
      <description>&lt;P&gt;Yes, this is the difference between using &lt;CODE&gt;where&lt;/CODE&gt; and &lt;CODE&gt;search&lt;/CODE&gt; ; &lt;CODE&gt;search&lt;/CODE&gt; can be basically used in the base/original search where as &lt;CODE&gt;where&lt;/CODE&gt; will compare/eval values of fields ... even back in 2014 &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;cheers, MuS&lt;/P&gt;</description>
      <pubDate>Wed, 08 Mar 2017 09:47:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122065#M32847</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2017-03-08T09:47:53Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a wildcard with a where clause?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122066#M32848</link>
      <description>&lt;P&gt;hi,&lt;BR /&gt;
if i want to add multiple values in the version field, can i use "AND" operator in search command?&lt;BR /&gt;
for eg: | search version= 10 AND 12 AND 13&lt;BR /&gt;
or how to include all three values in version field?&lt;/P&gt;</description>
      <pubDate>Tue, 16 Oct 2018 08:44:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122066#M32848</guid>
      <dc:creator>MoniM</dc:creator>
      <dc:date>2018-10-16T08:44:45Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a wildcard with a where clause?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122067#M32849</link>
      <description>&lt;P&gt;How about this?&lt;BR /&gt;
     .... | search version="10" version="12" version="13"&lt;/P&gt;</description>
      <pubDate>Tue, 16 Oct 2018 19:19:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-wildcard-with-a-where-clause/m-p/122067#M32849</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2018-10-16T19:19:26Z</dc:date>
    </item>
  </channel>
</rss>

