<?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 exclude result from query? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683370#M233357</link>
    <description>&lt;P&gt;It looks like you are excluding all the message=SUCCESS events, so you will never see them in the transaction data. If you want to exclude them, you will need to remove that &lt;STRONG&gt;message!="*(SUCCESS)*"&lt;/STRONG&gt; constraint.&lt;/P&gt;&lt;P&gt;Then your transaction will have the SUCCESS event included, so at that point, you can then filter out those events that have both succeeded then failed.&lt;/P&gt;&lt;P&gt;However, you will need to take care of ordering - you know your data, but can the SUCCESS come AFTER the fail?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 05 Apr 2024 07:11:32 GMT</pubDate>
    <dc:creator>bowesmana</dc:creator>
    <dc:date>2024-04-05T07:11:32Z</dc:date>
    <item>
      <title>How to exclude result from query?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683354#M233354</link>
      <description>&lt;P&gt;Hi Guys,&lt;/P&gt;&lt;P&gt;In my scenario i need show error details for correlation id .There are field called tracePoint="EXCEPTION" and message field with PRD(ERROR):&lt;/P&gt;&lt;P&gt;In some cases we have exception first after that the transaction got success.So at that time i want to ignore the transaction in my query.But its not ignoring the success correlationId in my result&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index="mulesoft" applicationName="s-concur-api" environment=PRD (tracePoint="EXCEPTION" AND message!="*(SUCCESS)*")|transaction correlationId | rename timestamp as Timestamp correlationId as CorrelationId tracePoint as TracePoint content.ErrorType as Error content.errorType
as errorType  content.errorMsg as ErrorMsg content.ErrorMsg as errorMsg
| eval ErrorType=if(isnull(Error),"Unknown",Error)
| dedup CorrelationId |eval errorType=coalesce(Error,errorType)|eval Errormsg=coalesce(ErrorMsg,errorMsg)
|table CorrelationId,Timestamp, applicationName, locationInfo.fileName, locationInfo.lineInFile, errorType, message,Errormsg
 | sort -Timestamp&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 Apr 2024 03:00:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683354#M233354</guid>
      <dc:creator>karthi2809</dc:creator>
      <dc:date>2024-04-05T03:00:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to exclude result from query?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683370#M233357</link>
      <description>&lt;P&gt;It looks like you are excluding all the message=SUCCESS events, so you will never see them in the transaction data. If you want to exclude them, you will need to remove that &lt;STRONG&gt;message!="*(SUCCESS)*"&lt;/STRONG&gt; constraint.&lt;/P&gt;&lt;P&gt;Then your transaction will have the SUCCESS event included, so at that point, you can then filter out those events that have both succeeded then failed.&lt;/P&gt;&lt;P&gt;However, you will need to take care of ordering - you know your data, but can the SUCCESS come AFTER the fail?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 Apr 2024 07:11:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683370#M233357</guid>
      <dc:creator>bowesmana</dc:creator>
      <dc:date>2024-04-05T07:11:32Z</dc:date>
    </item>
    <item>
      <title>Re: How to exclude result from query?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683383#M233359</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/205249"&gt;@karthi2809&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;Can you please try below with eventstats?&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index="mulesoft" applicationName="s-concur-api" environment=PRD 
| eventstats values(tracePoint) as TracePoints values(message) as Messages by correlationId 
| search TracePoints="EXCEPTION" Messages!="*(SUCCESS)*" 
| fields - TracePoints - Messages
| transaction correlationId 
| rename timestamp as Timestamp correlationId as CorrelationId tracePoint as TracePoint content.ErrorType as Error content.errorType
    as errorType content.errorMsg as ErrorMsg content.ErrorMsg as errorMsg 
| eval ErrorType=if(isnull(Error),"Unknown",Error) 
| dedup CorrelationId 
| eval errorType=coalesce(Error,errorType) 
| eval Errormsg=coalesce(ErrorMsg,errorMsg) 
| table CorrelationId,Timestamp, applicationName, locationInfo.fileName, locationInfo.lineInFile, errorType, message,Errormsg 
| sort -Timestamp&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 Apr 2024 10:02:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683383#M233359</guid>
      <dc:creator>scelikok</dc:creator>
      <dc:date>2024-04-05T10:02:03Z</dc:date>
    </item>
    <item>
      <title>Re: How to exclude result from query?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683385#M233360</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/206061"&gt;@scelikok&lt;/a&gt;&amp;nbsp; Yes its working But its showing all the timestamp and all the messages. Just i want to show error message not all transaction messages for the correlationId&lt;/P&gt;</description>
      <pubDate>Fri, 05 Apr 2024 10:10:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683385#M233360</guid>
      <dc:creator>karthi2809</dc:creator>
      <dc:date>2024-04-05T10:10:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to exclude result from query?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683386#M233361</link>
      <description>&lt;P&gt;You are right, I missed to filter again for exceptions. Please try below, you should see only correlationId exceptions that have no SUCCESS.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index="mulesoft" applicationName="s-concur-api" environment=PRD 
| eventstats values(tracePoint) as TracePoints values(message) as Messages by correlationId 
| search TracePoints="EXCEPTION" Messages!="*(SUCCESS)*" 
| fields - TracePoints - Messages
| search tracePoint="EXCEPTION"  
| transaction correlationId 
| rename timestamp as Timestamp correlationId as CorrelationId tracePoint as TracePoint content.ErrorType as Error content.errorType
    as errorType content.errorMsg as ErrorMsg content.ErrorMsg as errorMsg 
| eval ErrorType=if(isnull(Error),"Unknown",Error) 
| dedup CorrelationId 
| eval errorType=coalesce(Error,errorType) 
| eval Errormsg=coalesce(ErrorMsg,errorMsg) 
| table CorrelationId,Timestamp, applicationName, locationInfo.fileName, locationInfo.lineInFile, errorType, message,Errormsg 
| sort -Timestamp&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 Apr 2024 10:16:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-exclude-result-from-query/m-p/683386#M233361</guid>
      <dc:creator>scelikok</dc:creator>
      <dc:date>2024-04-05T10:16:07Z</dc:date>
    </item>
  </channel>
</rss>

