<?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 filter out specific rows in a table when the values come from JSON list ? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442598#M77116</link>
    <description>&lt;P&gt;@bugnet&lt;/P&gt;

&lt;P&gt;Can you please try this?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="alerts" 
| spath "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.value" 
| spath id 
| spath "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.type" 
| rename "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.type" as Type 
| rename "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.value" as Value 
| eval temp=mvzip(Type,Value) 
| mvexpand temp 
| eval Type = mvindex(split(temp,","),0), Value = mvindex(split(temp,","),1) 
| where Type="sector" 
| table Type Value id
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 27 Jun 2019 08:59:08 GMT</pubDate>
    <dc:creator>kamlesh_vaghela</dc:creator>
    <dc:date>2019-06-27T08:59:08Z</dc:date>
    <item>
      <title>How to filter out specific rows in a table when the values come from JSON list ?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442593#M77111</link>
      <description>&lt;P&gt;Hi all, &lt;/P&gt;

&lt;P&gt;I have a table like the one below, with a column containing 'Type', 'Value', 'alert id'.&lt;BR /&gt;
the problem is that the columns Type and Value coming from JSON list and I can't find a way to select specific values. &lt;BR /&gt;
I want to show in the table specific values with the same 'id'.&lt;/P&gt;

&lt;P&gt;Search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="alerts" | spath "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.value" | spath id | spath "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.type" | rename "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.type" as Type | rename "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.value" as Value | table Type Value id | where Type="sector"
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Results:  (I want to show only the sector Type)&lt;BR /&gt;
&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/7247i6C1CE3B023E3BF6C/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 26 Jun 2019 11:41:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442593#M77111</guid>
      <dc:creator>bugnet</dc:creator>
      <dc:date>2019-06-26T11:41:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to filter out specific rows in a table when the values come from JSON list ?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442594#M77112</link>
      <description>&lt;P&gt;You asked it (at the end of your search) for events where Type = sector, and both returned events do INDEED have "sector" in their Type.  What it is that you want instead - to return only the portions that actually correspond to the "sector" field?&lt;/P&gt;

&lt;P&gt;E.g. you would like a list that has 7 rows in it, corresponding to the 7 "sector" values?&lt;/P&gt;

&lt;P&gt;Does that sound right?&lt;/P&gt;</description>
      <pubDate>Wed, 26 Jun 2019 13:51:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442594#M77112</guid>
      <dc:creator>Richfez</dc:creator>
      <dc:date>2019-06-26T13:51:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to filter out specific rows in a table when the values come from JSON list ?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442595#M77113</link>
      <description>&lt;P&gt;@rich7177  Yes, I want to return only the portions that actually correspond to the "sector" field.&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jun 2019 07:45:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442595#M77113</guid>
      <dc:creator>bugnet</dc:creator>
      <dc:date>2019-06-27T07:45:38Z</dc:date>
    </item>
    <item>
      <title>Re: How to filter out specific rows in a table when the values come from JSON list ?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442596#M77114</link>
      <description>&lt;P&gt;@bugnet &lt;/P&gt;

&lt;P&gt;Can you please share sample event with masking values AND expected results?? &lt;/P&gt;</description>
      <pubDate>Thu, 27 Jun 2019 07:51:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442596#M77114</guid>
      <dc:creator>kamlesh_vaghela</dc:creator>
      <dc:date>2019-06-27T07:51:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to filter out specific rows in a table when the values come from JSON list ?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442597#M77115</link>
      <description>&lt;P&gt;Expected results: &lt;/P&gt;

&lt;P&gt;&lt;A href="https://ibb.co/RNxsJtY"&gt;https://ibb.co/RNxsJtY&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jun 2019 08:18:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442597#M77115</guid>
      <dc:creator>bugnet</dc:creator>
      <dc:date>2019-06-27T08:18:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to filter out specific rows in a table when the values come from JSON list ?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442598#M77116</link>
      <description>&lt;P&gt;@bugnet&lt;/P&gt;

&lt;P&gt;Can you please try this?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index="alerts" 
| spath "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.value" 
| spath id 
| spath "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.type" 
| rename "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.type" as Type 
| rename "MISP{}.FullContext{}.Event.Galaxy{}.GalaxyCluster{}.value" as Value 
| eval temp=mvzip(Type,Value) 
| mvexpand temp 
| eval Type = mvindex(split(temp,","),0), Value = mvindex(split(temp,","),1) 
| where Type="sector" 
| table Type Value id
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 27 Jun 2019 08:59:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/How-to-filter-out-specific-rows-in-a-table-when-the-values-come/m-p/442598#M77116</guid>
      <dc:creator>kamlesh_vaghela</dc:creator>
      <dc:date>2019-06-27T08:59:08Z</dc:date>
    </item>
  </channel>
</rss>

