<?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: Trouble creating a Pie Chart with URL filtering in All Apps and Add-ons</title>
    <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/Trouble-creating-a-Pie-Chart-with-URL-filtering/m-p/400623#M48873</link>
    <description>&lt;P&gt;Thanks! This simplified things.&lt;/P&gt;</description>
    <pubDate>Fri, 23 Nov 2018 16:26:23 GMT</pubDate>
    <dc:creator>DeanDeleon0</dc:creator>
    <dc:date>2018-11-23T16:26:23Z</dc:date>
    <item>
      <title>Trouble creating a Pie Chart with URL filtering</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/Trouble-creating-a-Pie-Chart-with-URL-filtering/m-p/400621#M48871</link>
      <description>&lt;P&gt;Hello all!&lt;/P&gt;

&lt;P&gt;I am using the dashboards generated in the Palo Alto Networks App and attempting to divide the http_category (for URL filtering) to group them into specific other categories and then create a Pie Chart of the results.  The results of the search add the count of each correctly, but I am unable to how this work "visually".&lt;/P&gt;

&lt;P&gt;Basically I want to flag specific "http_category" events as "Good", "Bad", and "Grey area" as an example.  So that  "Bad" could contain sports, shopping and games,  "Good" could contain government, legal and news, etc...&lt;/P&gt;

&lt;P&gt;I am able to get correct numbers (by adding them up manually to verify)  with this following search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| tstats  values(log.flags) AS log.flags, count FROM datamodel=pan_firewall WHERE nodename="log.url"     """"    log.action="*" GROUPBY _time log.dest_name log.app:category log.http_category log.app log.action log.content_type log.vendor_action | rename log.* AS * | stats sum(eval(http_category="sports" OR http_category="shopping" OR http_category="games")) as bad, sum(eval(http_category="legal" OR http_category="government" OR http_category="news")) as good, sum(eval(http_category="music" OR http_category="religion" OR http_category="media")) as "grey area"
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Any suggestions on how I can resolve this or am I looking at this completely wrong?  Any help with be very much appreciated.&lt;/P&gt;

&lt;P&gt;Thanks,&lt;/P&gt;

&lt;P&gt;Dean&lt;/P&gt;</description>
      <pubDate>Wed, 21 Nov 2018 21:02:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/Trouble-creating-a-Pie-Chart-with-URL-filtering/m-p/400621#M48871</guid>
      <dc:creator>DeanDeleon0</dc:creator>
      <dc:date>2018-11-21T21:02:45Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble creating a Pie Chart with URL filtering</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/Trouble-creating-a-Pie-Chart-with-URL-filtering/m-p/400622#M48872</link>
      <description>&lt;P&gt;Rather than trying to sum an eval, my suggestion is to create a lookup.  The lookup could have two columns:  &lt;CODE&gt;http_category&lt;/CODE&gt;, &lt;CODE&gt;http_category_verdict&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;For each http category, set a verdict of &lt;CODE&gt;good&lt;/CODE&gt;, &lt;CODE&gt;bad&lt;/CODE&gt;, or &lt;CODE&gt;gray area&lt;/CODE&gt;.  Then, whenever you have results with an http_category field, just pipe to the lookup table:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;rest of search&amp;gt; | lookup your-lookup-table http_category
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;That will reference the lookup table and add a field called &lt;CODE&gt;http_category_verdict&lt;/CODE&gt; to each log based on the http category of each log.&lt;/P&gt;

&lt;P&gt;Hope that helps!&lt;/P&gt;</description>
      <pubDate>Wed, 21 Nov 2018 23:20:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/Trouble-creating-a-Pie-Chart-with-URL-filtering/m-p/400622#M48872</guid>
      <dc:creator>btorresgil</dc:creator>
      <dc:date>2018-11-21T23:20:57Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble creating a Pie Chart with URL filtering</title>
      <link>https://community.splunk.com/t5/All-Apps-and-Add-ons/Trouble-creating-a-Pie-Chart-with-URL-filtering/m-p/400623#M48873</link>
      <description>&lt;P&gt;Thanks! This simplified things.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Nov 2018 16:26:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/All-Apps-and-Add-ons/Trouble-creating-a-Pie-Chart-with-URL-filtering/m-p/400623#M48873</guid>
      <dc:creator>DeanDeleon0</dc:creator>
      <dc:date>2018-11-23T16:26:23Z</dc:date>
    </item>
  </channel>
</rss>

