<?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: User data collapsed with activity information collected in separate statements in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241738#M71908</link>
    <description>&lt;P&gt;What is your current search statement?&lt;/P&gt;</description>
    <pubDate>Thu, 30 Jun 2016 14:20:35 GMT</pubDate>
    <dc:creator>richgalloway</dc:creator>
    <dc:date>2016-06-30T14:20:35Z</dc:date>
    <item>
      <title>User data collapsed with activity information collected in separate statements</title>
      <link>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241737#M71907</link>
      <description>&lt;P&gt;My app writes two log statements, audit and activity statement, for each invocation as below:&lt;/P&gt;

&lt;P&gt;audit:&lt;BR /&gt;
type:audit | tid:123 | userid:abc&lt;/P&gt;

&lt;P&gt;activity:&lt;BR /&gt;
type:activity | tid:123 | action:login&lt;/P&gt;

&lt;P&gt;Need is to  get a sense of what the user has done by displaying the userid and collapsing the action into a table. &lt;/P&gt;

&lt;P&gt;What I tried so far is to define a transaction on audit log and collapsed all tid for a given user which displays data as below:&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;userid        |             tid&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;abc   |                        123&lt;BR /&gt;
          |                       345&lt;/P&gt;

&lt;H2&gt;          |                        876&lt;/H2&gt;

&lt;P&gt;xyz    |                       793&lt;BR /&gt;
          |                    438&lt;/P&gt;

&lt;P&gt;How to show action values from activity instead of tid ?&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2016 14:06:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241737#M71907</guid>
      <dc:creator>sureshchinta</dc:creator>
      <dc:date>2016-06-30T14:06:42Z</dc:date>
    </item>
    <item>
      <title>Re: User data collapsed with activity information collected in separate statements</title>
      <link>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241738#M71908</link>
      <description>&lt;P&gt;What is your current search statement?&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2016 14:20:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241738#M71908</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2016-06-30T14:20:35Z</dc:date>
    </item>
    <item>
      <title>Re: User data collapsed with activity information collected in separate statements</title>
      <link>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241739#M71909</link>
      <description>&lt;P&gt;Try this (assuming all fields have been extracted) &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=webapp host=pxdtp00* (audit* OR activity*) | rex "(?&amp;lt;Action&amp;gt;audit|activity)"  | stats values(Action) as Action by UserId TxnId | mvexpand Action
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;UPDATED to include field extraction&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2016 14:24:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241739#M71909</guid>
      <dc:creator>sundareshr</dc:creator>
      <dc:date>2016-06-30T14:24:35Z</dc:date>
    </item>
    <item>
      <title>Re: User data collapsed with activity information collected in separate statements</title>
      <link>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241740#M71910</link>
      <description>&lt;PRE&gt;&lt;CODE&gt;index=webapp host=pxdtp00* AND audit* | transaction UserId | table UserId TxnId | join TxnId [search index=webapp host=pxdtp00* activity* | stats Action by TxnId ] | table UserId Action TxnId
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;search before join collapses all txnId fields for a given user. Next search is not able to complement action into the mix.&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2016 17:57:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241740#M71910</guid>
      <dc:creator>sureshchinta</dc:creator>
      <dc:date>2016-06-30T17:57:01Z</dc:date>
    </item>
    <item>
      <title>Re: User data collapsed with activity information collected in separate statements</title>
      <link>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241741#M71911</link>
      <description>&lt;P&gt;Try the updated query. I modified it to include field extraction.&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2016 19:16:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241741#M71911</guid>
      <dc:creator>sundareshr</dc:creator>
      <dc:date>2016-06-30T19:16:29Z</dc:date>
    </item>
    <item>
      <title>Re: User data collapsed with activity information collected in separate statements</title>
      <link>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241742#M71912</link>
      <description>&lt;P&gt;This query is getting results as wanted.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=webapp host=host* AND IntegrationFrameworkV01 AND audit* |  dedup TxnId | table UserId TxnId | join TxnId [search index=webapp host=host* AND IntegrationFrameworkV01 AND client:* | eval Date_Time = strftime(_time, "%m/%d/%y %H:%M:%S")  | stats values(Action) as Action sum(eval(ReqLatency + AppLatency + ResLatency)) as Latency by TxnId HttpCode Date_Time  ]  | stats list(Action) as Action list(Latency) as Latency list(HttpCode) as HttpCode list(Date_Time) as DateTIme by UserId  | table UserId Action DateTIme Latency HttpCode
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Job indicates, &lt;/P&gt;

&lt;BLOCKQUOTE&gt;
&lt;P&gt;'stats' command: limit for values of field 'DP_IF_Action' reached. Some values may have been truncated or ignored.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;

&lt;P&gt;How to stop truncating results ?&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 10:13:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/User-data-collapsed-with-activity-information-collected-in/m-p/241742#M71912</guid>
      <dc:creator>sureshchinta</dc:creator>
      <dc:date>2020-09-29T10:13:20Z</dc:date>
    </item>
  </channel>
</rss>

