<?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: filter multivalue of strings by substring/character in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-filter-multivalue-of-strings-by-substring-character/m-p/590405#M48463</link>
    <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/242896"&gt;@Kubousky&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;If the field coordinatorsID is present as a column of the table, try expanding the field using mvexpand first, and then extract the field expertiseLevel from the coordinatorsID using regex. This will create a separate column for the expertiseLevel and then you can filter your data using the search command. Roughly your query should look something like this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;&amp;lt;your_base_query&amp;gt;&amp;gt;
| mvexpand coordinatorsID
| rex field=coordinatorsID "[a-zA-Z]##(?&amp;lt;expertiseLevel&amp;gt;\d)"
| search expertiseLevel="3"&lt;/LI-CODE&gt;</description>
    <pubDate>Wed, 23 Mar 2022 11:53:04 GMT</pubDate>
    <dc:creator>tshah-splunk</dc:creator>
    <dc:date>2022-03-23T11:53:04Z</dc:date>
    <item>
      <title>How to filter multivalue of strings by substring/character?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-filter-multivalue-of-strings-by-substring-character/m-p/590399#M48462</link>
      <description>&lt;P&gt;I need to filter multivalue of strings by substring/character.&lt;/P&gt;
&lt;P&gt;field &lt;U&gt;coordinatorsID&lt;/U&gt;: a##1, b##2, c##3, d##3&lt;/P&gt;
&lt;P&gt;field &lt;U&gt;expertiseLevel&lt;/U&gt; can be one of&amp;nbsp; "1", "2", "3"&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;Exmple:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;expertiseLevel = "3"&lt;/P&gt;
&lt;P&gt;result -&amp;gt;&amp;nbsp; c##3, d##3&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;What I tried:&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;attempt1:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;| eval&amp;nbsp;coordinatorsID_filtered = mvfilter(like(coordinatorsID,"%$expertiseLevel$"))&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; error&lt;/P&gt;
&lt;P&gt;attempt2:&lt;/P&gt;
&lt;P&gt;| eval&amp;nbsp;expertiseLevel = case(expertiseLevel == "1", "%1", expertiseLevel == "2", "%2", expertiseLevel == "3", "%3")&lt;/P&gt;
&lt;P&gt;&amp;nbsp;| eval&amp;nbsp;coordinatorsID_filtered = mvfilter(like(coordinatorsID,$expertiseLevel$))&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;null&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 23 Mar 2022 22:44:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-filter-multivalue-of-strings-by-substring-character/m-p/590399#M48462</guid>
      <dc:creator>Kubousky</dc:creator>
      <dc:date>2022-03-23T22:44:05Z</dc:date>
    </item>
    <item>
      <title>Re: filter multivalue of strings by substring/character</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-filter-multivalue-of-strings-by-substring-character/m-p/590405#M48463</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/242896"&gt;@Kubousky&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;If the field coordinatorsID is present as a column of the table, try expanding the field using mvexpand first, and then extract the field expertiseLevel from the coordinatorsID using regex. This will create a separate column for the expertiseLevel and then you can filter your data using the search command. Roughly your query should look something like this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;&amp;lt;your_base_query&amp;gt;&amp;gt;
| mvexpand coordinatorsID
| rex field=coordinatorsID "[a-zA-Z]##(?&amp;lt;expertiseLevel&amp;gt;\d)"
| search expertiseLevel="3"&lt;/LI-CODE&gt;</description>
      <pubDate>Wed, 23 Mar 2022 11:53:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-filter-multivalue-of-strings-by-substring-character/m-p/590405#M48463</guid>
      <dc:creator>tshah-splunk</dc:creator>
      <dc:date>2022-03-23T11:53:04Z</dc:date>
    </item>
  </channel>
</rss>

