<?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: getting  duplicate fields from splunk result in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/getting-duplicate-fields-from-splunk-result/m-p/201586#M39921</link>
    <description>&lt;P&gt;you may try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | eventstats count by src_ip ,dest_ip | where count = 2
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Tue, 01 Sep 2015 09:07:09 GMT</pubDate>
    <dc:creator>chanmi2</dc:creator>
    <dc:date>2015-09-01T09:07:09Z</dc:date>
    <item>
      <title>getting  duplicate fields from splunk result</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/getting-duplicate-fields-from-splunk-result/m-p/201584#M39919</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;My requirement is to find is same pair of source and ip addresses are being used.&lt;BR /&gt;
for example if this is my table&lt;/P&gt;

&lt;P&gt;src_ip ,dest_ip,action&lt;BR /&gt;
192.168.10.2,192.168.10.3,block&lt;BR /&gt;
192.168.10.21,192.168.10.13,block&lt;BR /&gt;
192.168.10.2,192.168.10.3,allow&lt;/P&gt;

&lt;P&gt;i want as a result:&lt;BR /&gt;
192.168.10.2,192.168.10.3,allow&lt;BR /&gt;
192.168.10.2,192.168.10.3,block&lt;/P&gt;

&lt;P&gt;How to achieve this?&lt;/P&gt;

&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 07:09:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/getting-duplicate-fields-from-splunk-result/m-p/201584#M39919</guid>
      <dc:creator>ektasiwani</dc:creator>
      <dc:date>2020-09-29T07:09:03Z</dc:date>
    </item>
    <item>
      <title>Re: getting  duplicate fields from splunk result</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/getting-duplicate-fields-from-splunk-result/m-p/201585#M39920</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;you can use the dedup command:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | dedup src_ip dest_ip action
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;or you can use stats:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | stats count by src_ip dest_ip action | fields -count
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;If possible, you should use stats, it should be faster than dedup. But without further ado, after a stats you only have the fields left, that you used in your by clause.&lt;/P&gt;

&lt;P&gt;Greetings&lt;/P&gt;

&lt;P&gt;Tom&lt;/P&gt;</description>
      <pubDate>Mon, 31 Aug 2015 09:38:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/getting-duplicate-fields-from-splunk-result/m-p/201585#M39920</guid>
      <dc:creator>tom_frotscher</dc:creator>
      <dc:date>2015-08-31T09:38:01Z</dc:date>
    </item>
    <item>
      <title>Re: getting  duplicate fields from splunk result</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/getting-duplicate-fields-from-splunk-result/m-p/201586#M39921</link>
      <description>&lt;P&gt;you may try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | eventstats count by src_ip ,dest_ip | where count = 2
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 01 Sep 2015 09:07:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/getting-duplicate-fields-from-splunk-result/m-p/201586#M39921</guid>
      <dc:creator>chanmi2</dc:creator>
      <dc:date>2015-09-01T09:07:09Z</dc:date>
    </item>
  </channel>
</rss>

