<?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: Get logs with a distinct value of a field in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Get-logs-with-a-distinct-value-of-a-field/m-p/405753#M117294</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;Actually dedup TransactionID should work if you are looking for distinct transactions.&lt;/P&gt;

&lt;P&gt;But if you are looking for all the logs per each transaction, you can try transaction command.&lt;/P&gt;

&lt;P&gt;index=bc-dag-app AND ERROR | transaction TransactionID&lt;/P&gt;

&lt;P&gt;Hope, it helps. &lt;/P&gt;</description>
    <pubDate>Thu, 11 Apr 2019 17:33:23 GMT</pubDate>
    <dc:creator>cvssravan</dc:creator>
    <dc:date>2019-04-11T17:33:23Z</dc:date>
    <item>
      <title>Get logs with a distinct value of a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Get-logs-with-a-distinct-value-of-a-field/m-p/405752#M117293</link>
      <description>&lt;P&gt;I saw some similar questions but none seem to work&lt;/P&gt;

&lt;P&gt;In my splunk logs, I have this field called &lt;STRONG&gt;TransactionID: 6c5802f0-c317-4d3a-9211-2ed7a10a5d7f -&amp;gt; 46314ef3-dac8-4756-902a-76fc61255d11&lt;/STRONG&gt; in my logs&lt;BR /&gt;
A &lt;EM&gt;transaction can have multiple errors&lt;/EM&gt; but I just want to find how many transactions did error occur in instead of total number of errors.&lt;BR /&gt;
In other words, I want logs of distinct TransactionID that has error. &lt;/P&gt;

&lt;P&gt;I tried &lt;STRONG&gt;index=bc-dag-app AND ERROR | dedup TransactionID&lt;/STRONG&gt; but it didn't work.&lt;BR /&gt;
Can someone please advise?&lt;/P&gt;

&lt;P&gt;PS: I am super-new to splunk so I'm sorry if it's a straight forward/stupid question&lt;/P&gt;</description>
      <pubDate>Thu, 11 Apr 2019 16:42:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Get-logs-with-a-distinct-value-of-a-field/m-p/405752#M117293</guid>
      <dc:creator>ank15july96</dc:creator>
      <dc:date>2019-04-11T16:42:09Z</dc:date>
    </item>
    <item>
      <title>Re: Get logs with a distinct value of a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Get-logs-with-a-distinct-value-of-a-field/m-p/405753#M117294</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;Actually dedup TransactionID should work if you are looking for distinct transactions.&lt;/P&gt;

&lt;P&gt;But if you are looking for all the logs per each transaction, you can try transaction command.&lt;/P&gt;

&lt;P&gt;index=bc-dag-app AND ERROR | transaction TransactionID&lt;/P&gt;

&lt;P&gt;Hope, it helps. &lt;/P&gt;</description>
      <pubDate>Thu, 11 Apr 2019 17:33:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Get-logs-with-a-distinct-value-of-a-field/m-p/405753#M117294</guid>
      <dc:creator>cvssravan</dc:creator>
      <dc:date>2019-04-11T17:33:23Z</dc:date>
    </item>
    <item>
      <title>Re: Get logs with a distinct value of a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Get-logs-with-a-distinct-value-of-a-field/m-p/405754#M117295</link>
      <description>&lt;P&gt;I tried the above query but it did not yield any result. &lt;span class="lia-unicode-emoji" title=":confused_face:"&gt;😕&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 11 Apr 2019 20:08:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Get-logs-with-a-distinct-value-of-a-field/m-p/405754#M117295</guid>
      <dc:creator>ank15july96</dc:creator>
      <dc:date>2019-04-11T20:08:53Z</dc:date>
    </item>
    <item>
      <title>Re: Get logs with a distinct value of a field</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Get-logs-with-a-distinct-value-of-a-field/m-p/405755#M117296</link>
      <description>&lt;P&gt;@ank15july96 First make sure your TransactionID field is being extracted. If it is, then use below query -&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=bc-dag-app AND ERROR | stats dc(TransactionID) as error_count
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 11 Apr 2019 21:17:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Get-logs-with-a-distinct-value-of-a-field/m-p/405755#M117296</guid>
      <dc:creator>Vijeta</dc:creator>
      <dc:date>2019-04-11T21:17:01Z</dc:date>
    </item>
  </channel>
</rss>

