<?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 how to iterate a column's values like python in command? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/how-to-iterate-a-column-s-values-like-python-in-command/m-p/299548#M160252</link>
    <description>&lt;P&gt;"daily.cld"  | rex field=_raw "version: (?\d+.)," | rex field=_raw "sigs: (?\d+.)," | convert timeformat="%Y-%m-%d" ctime(_time) AS date  | table source, date, version, sigs | where date=strftime(now(), "%Y-%m-%d")&lt;/P&gt;

&lt;P&gt;is there a command like python to find missing server log file?&lt;/P&gt;

&lt;P&gt;input a correct full list of name ["name1", "name2", "name3"]&lt;BR /&gt;
and compare with the columns values , to find which name in full list not in the values of columns of search table&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 14:47:26 GMT</pubDate>
    <dc:creator>cyberportnoc</dc:creator>
    <dc:date>2020-09-29T14:47:26Z</dc:date>
    <item>
      <title>how to iterate a column's values like python in command?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-iterate-a-column-s-values-like-python-in-command/m-p/299548#M160252</link>
      <description>&lt;P&gt;"daily.cld"  | rex field=_raw "version: (?\d+.)," | rex field=_raw "sigs: (?\d+.)," | convert timeformat="%Y-%m-%d" ctime(_time) AS date  | table source, date, version, sigs | where date=strftime(now(), "%Y-%m-%d")&lt;/P&gt;

&lt;P&gt;is there a command like python to find missing server log file?&lt;/P&gt;

&lt;P&gt;input a correct full list of name ["name1", "name2", "name3"]&lt;BR /&gt;
and compare with the columns values , to find which name in full list not in the values of columns of search table&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 14:47:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-iterate-a-column-s-values-like-python-in-command/m-p/299548#M160252</guid>
      <dc:creator>cyberportnoc</dc:creator>
      <dc:date>2020-09-29T14:47:26Z</dc:date>
    </item>
    <item>
      <title>Re: how to iterate a column's values like python in command?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-iterate-a-column-s-values-like-python-in-command/m-p/299549#M160253</link>
      <description>&lt;P&gt;Hi cyberportnoc,&lt;/P&gt;

&lt;P&gt;create a lookup with all your servers (e.g. perimeter.csv) calling column host and possibly using only uppercase (not mandatory)&lt;BR /&gt;
run this search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;your search
| eval host=upper(host)
| stats count by host
| append [ | inputlookup perimeter.csv | eval host=upper(host), count=0 | fields host count ]
| stats sum(count) AS Total by host
| where Total = 0
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;In this way you listed all missing hosts.&lt;BR /&gt;
without the last condition (where Total=0) you have the status of all your servers that you can display in a dashboard also in graphic mode.&lt;/P&gt;

&lt;P&gt;Bye.&lt;BR /&gt;
Giuseppe&lt;/P&gt;</description>
      <pubDate>Mon, 10 Jul 2017 09:23:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-iterate-a-column-s-values-like-python-in-command/m-p/299549#M160253</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2017-07-10T09:23:53Z</dc:date>
    </item>
  </channel>
</rss>

