<?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 Use Field Values in Endswith Parameter of Transactions in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-Use-Field-Values-in-Endswith-Parameter-of-Transactions/m-p/549193#M155805</link>
    <description>&lt;P&gt;Hello!&lt;/P&gt;&lt;P&gt;I am trying to group my log entries based on very specific criteria but can't seem to figure out how to do so.&lt;/P&gt;&lt;P&gt;I have logs like this:&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:26&amp;nbsp; User Id: 6211 Error Resolved&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:25&amp;nbsp; Error[0] type 800&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:25&amp;nbsp; User Id: 2345 Error Resolved&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:23&amp;nbsp; Error[0] Error Response {"user_id":2345, "error_id":9101, ..............etc}&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:23&amp;nbsp; Error[0] type 800&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:22&amp;nbsp; Error[0]&amp;nbsp;Error Response {"user_id":6211, "error_id":9100, ..............etc}&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:22&amp;nbsp; Error[0] type 800&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to get three events in my transactions: (1) the initial error type message, (2) the error response details, and (3) the error resolved message. However, I need the error response details and the error resolved message to contain the same user id. I currently have my query set up like this:&lt;/P&gt;&lt;P&gt;index=INDEX host=HOSTNAME sourcetype=SOURCETYPE&lt;BR /&gt;| rex field=_raw "Error\[0\]\stype\s(?&amp;lt;error_code&amp;gt;\d+)"&lt;BR /&gt;| rex field=_raw "User\sId:(?&amp;lt;user_id&amp;gt;\d+)\sError\sResolved"&lt;BR /&gt;| rex field=_raw "Error\[0\]\sError\sResponse\s{\"user_id\":(?&amp;lt;user_id&amp;gt;\d+)"&lt;BR /&gt;| where user_id&amp;lt;20000 or error_code=800&lt;BR /&gt;| transaction startswith="Error[0] type 800" endswith="User Id:"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm lost on how to make sure that the transaction retrieves only the events where the user id of the error response details matches the error resolved message. Any ideas?&lt;/P&gt;</description>
    <pubDate>Fri, 23 Apr 2021 21:08:45 GMT</pubDate>
    <dc:creator>Traer001</dc:creator>
    <dc:date>2021-04-23T21:08:45Z</dc:date>
    <item>
      <title>How to Use Field Values in Endswith Parameter of Transactions</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-Use-Field-Values-in-Endswith-Parameter-of-Transactions/m-p/549193#M155805</link>
      <description>&lt;P&gt;Hello!&lt;/P&gt;&lt;P&gt;I am trying to group my log entries based on very specific criteria but can't seem to figure out how to do so.&lt;/P&gt;&lt;P&gt;I have logs like this:&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:26&amp;nbsp; User Id: 6211 Error Resolved&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:25&amp;nbsp; Error[0] type 800&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:25&amp;nbsp; User Id: 2345 Error Resolved&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:23&amp;nbsp; Error[0] Error Response {"user_id":2345, "error_id":9101, ..............etc}&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:23&amp;nbsp; Error[0] type 800&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:22&amp;nbsp; Error[0]&amp;nbsp;Error Response {"user_id":6211, "error_id":9100, ..............etc}&lt;/P&gt;&lt;P&gt;2021-04-23 16:47:22&amp;nbsp; Error[0] type 800&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to get three events in my transactions: (1) the initial error type message, (2) the error response details, and (3) the error resolved message. However, I need the error response details and the error resolved message to contain the same user id. I currently have my query set up like this:&lt;/P&gt;&lt;P&gt;index=INDEX host=HOSTNAME sourcetype=SOURCETYPE&lt;BR /&gt;| rex field=_raw "Error\[0\]\stype\s(?&amp;lt;error_code&amp;gt;\d+)"&lt;BR /&gt;| rex field=_raw "User\sId:(?&amp;lt;user_id&amp;gt;\d+)\sError\sResolved"&lt;BR /&gt;| rex field=_raw "Error\[0\]\sError\sResponse\s{\"user_id\":(?&amp;lt;user_id&amp;gt;\d+)"&lt;BR /&gt;| where user_id&amp;lt;20000 or error_code=800&lt;BR /&gt;| transaction startswith="Error[0] type 800" endswith="User Id:"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm lost on how to make sure that the transaction retrieves only the events where the user id of the error response details matches the error resolved message. Any ideas?&lt;/P&gt;</description>
      <pubDate>Fri, 23 Apr 2021 21:08:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-Use-Field-Values-in-Endswith-Parameter-of-Transactions/m-p/549193#M155805</guid>
      <dc:creator>Traer001</dc:creator>
      <dc:date>2021-04-23T21:08:45Z</dc:date>
    </item>
  </channel>
</rss>

