<?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 display differences week by week IP address data in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583810#M203308</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/242808"&gt;@balzac13dark&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;yu could run something like this:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=your_index earliest=-14d@d latest=@d
| eval week=if(today()-_time&amp;lt;604400,"Second Week","First Week")
| stats dc(week) AS dc_week values(week) AS week BY dest
| eval week=if(dc_week=2,"Both Weeks", if(week="Second Week","Only Second Week","Only First Week"))
| table dest week&lt;/LI-CODE&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
    <pubDate>Sat, 05 Feb 2022 07:24:01 GMT</pubDate>
    <dc:creator>gcusello</dc:creator>
    <dc:date>2022-02-05T07:24:01Z</dc:date>
    <item>
      <title>How to display differences week by week IP address data</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583805#M203306</link>
      <description>&lt;P&gt;I'm splunk beginner.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to know which destination IP addresses are used on my enterprise infra by using firewall log and would like to display dest_ip result on 1st week then display only differences between 1st &amp;amp; 2nd week one and so on...&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can someone help which query Ii should use ?&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 05 Feb 2022 04:26:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583805#M203306</guid>
      <dc:creator>balzac13dark</dc:creator>
      <dc:date>2022-02-05T04:26:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to display differences week by week IP address data</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583809#M203307</link>
      <description>&lt;P&gt;It's not obvious what you mean by "difference". For example, if an IP was connected to in week 1 and 3 should it be listed in week 3 or not?&lt;/P&gt;</description>
      <pubDate>Sat, 05 Feb 2022 07:13:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583809#M203307</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2022-02-05T07:13:56Z</dc:date>
    </item>
    <item>
      <title>Re: How to display differences week by week IP address data</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583810#M203308</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/242808"&gt;@balzac13dark&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;yu could run something like this:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=your_index earliest=-14d@d latest=@d
| eval week=if(today()-_time&amp;lt;604400,"Second Week","First Week")
| stats dc(week) AS dc_week values(week) AS week BY dest
| eval week=if(dc_week=2,"Both Weeks", if(week="Second Week","Only Second Week","Only First Week"))
| table dest week&lt;/LI-CODE&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Sat, 05 Feb 2022 07:24:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583810#M203308</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-02-05T07:24:01Z</dc:date>
    </item>
    <item>
      <title>Re: How to display differences week by week IP address data</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583813#M203311</link>
      <description>&lt;P&gt;But what if you wanted to extend this to more weeks? &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 05 Feb 2022 07:52:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583813#M203311</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2022-02-05T07:52:53Z</dc:date>
    </item>
    <item>
      <title>Re: How to display differences week by week IP address data</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583837#M203317</link>
      <description>&lt;P&gt;thank you ! i tried but found below error.. would you help ?&lt;/P&gt;&lt;P&gt;The 'today' function is unsupported or undefined&amp;nbsp;&lt;/P&gt;&lt;P&gt;My explanation was not clear. What i want was to display All dest IP result on first week then display IP not shown on first week as a second week result, then 3rd week, 4th week and so on...&amp;nbsp; &amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 06 Feb 2022 05:57:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583837#M203317</guid>
      <dc:creator>balzac13dark</dc:creator>
      <dc:date>2022-02-06T05:57:14Z</dc:date>
    </item>
    <item>
      <title>Re: How to display differences week by week IP address data</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583839#M203318</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/242808"&gt;@balzac13dark&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;sorry I was confused, the function is now(), please try this:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=your_index earliest=-14d@d latest=@d
| eval week=if(now()-_time&amp;lt;604400,"Second Week","First Week")
| stats dc(week) AS dc_week values(week) AS week BY dest
| eval week=if(dc_week=2,"Both Weeks", if(week="Second Week","Only Second Week","Only First Week"))
| table dest week&lt;/LI-CODE&gt;&lt;P&gt;With this search you monitor the last two weeks events and you know if a dest is present only in the first wee, only in the secondo or both.&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Sun, 06 Feb 2022 07:03:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583839#M203318</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-02-06T07:03:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to display differences week by week IP address data</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583896#M203342</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/161352"&gt;@gcusello&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;thank you so much !! it's working fine now. i could get results on last week &amp;amp; this week.&lt;/P&gt;&lt;P&gt;but if you could help me more below, it'd be highly appreciated.&lt;/P&gt;&lt;P&gt;* obtain day by day IP address difference reports for next 3month.&lt;/P&gt;&lt;P&gt;e.g.&lt;/P&gt;&lt;P&gt;day#1 result : IP a), b), c)&amp;nbsp; -&amp;gt; IP a), b), c) are displayed&lt;/P&gt;&lt;P&gt;day#2 result :&amp;nbsp;IP a), b), c),&amp;nbsp; d)&amp;nbsp; -&amp;gt; Only different than day#1 "IP d)" is displayed&amp;nbsp;&lt;/P&gt;&lt;P&gt;day#3 result :&amp;nbsp;&amp;nbsp;IP a), b), d), e)&amp;nbsp; -&amp;gt;&amp;nbsp;Only different than day#1 &amp;amp; day#2 "IP e)" is displayed&lt;/P&gt;&lt;P&gt;day#4 result :&amp;nbsp;&amp;nbsp;IP&amp;nbsp; b), d), e), f)&amp;nbsp; &amp;nbsp;-&amp;gt;&amp;nbsp;Only different than day#1, day#2 &amp;amp; day#3&amp;nbsp; "IP f)" is displayed&lt;/P&gt;&lt;P&gt;and day#5, 6, 7 and so on...&lt;/P&gt;</description>
      <pubDate>Mon, 07 Feb 2022 06:25:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583896#M203342</guid>
      <dc:creator>balzac13dark</dc:creator>
      <dc:date>2022-02-07T06:25:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to display differences week by week IP address data</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583902#M203344</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/242808"&gt;@balzac13dark&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;godd for you that the last answer was the right one!&lt;/P&gt;&lt;P&gt;about the new question, for the next time, please, open a new different question!&lt;/P&gt;&lt;P&gt;Anyway, let mew understand: you want to know the new IPs for each day respect the previous days, is it correct?&lt;/P&gt;&lt;P&gt;only one question: you spoke about three months as time priod, but probablt these thre months are the last three monts from the present day, is it correct?&lt;/P&gt;&lt;P&gt;In other words today, you count from the 7th of november, tomorrow from the 8th of november and so on, is it correct?&lt;/P&gt;&lt;P&gt;In this case, the only approach that I can think is to use a summary index:&lt;/P&gt;&lt;P&gt;you should schedule a search like my previous answer that runs every night ans saves results in a summary index, something like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=your_index earliest=-90d@d latest=@d
| bin _time span=1d
| eval day=if(now()-_time&amp;lt;90000,"New","Already Present")
| stats dc(day) AS dc_day values(day) AS day values(_time) AS _time BY IP
| eval day=if(dc_day=2,"Always Present", if(day="New","New","Only Previous"))
| mvexpand _time
| table IP day _time
| collect index=summary_statistics&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then you could run a search on the summary index:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=summary_statistics
| eval day=if(now()-_time&amp;lt;90000,"New","Already Present")
| table IP status&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;&lt;P&gt;P.S.: Karma Points are appreciated by all the Contributors &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 07 Feb 2022 07:26:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583902#M203344</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-02-07T07:26:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to display differences week by week IP address data</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583915#M203345</link>
      <description>&lt;P&gt;Ha! So that's the answer to my initial question.&lt;/P&gt;&lt;P&gt;You want only "incremental differences", not the "baseline differences". I'd go for something like this:&lt;/P&gt;&lt;PRE&gt;&amp;lt;your search&amp;gt;&lt;BR /&gt;| bin _time span=1d (or whatever you need)&lt;BR /&gt;| stats earliest(_time) as _time by ip&lt;BR /&gt;| stats values(ip) by _time&lt;BR /&gt;| sort _time&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 07 Feb 2022 10:29:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-display-differences-week-by-week-IP-address-data/m-p/583915#M203345</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2022-02-07T10:29:26Z</dc:date>
    </item>
  </channel>
</rss>

