<?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 extract the Referrer Field from the first event of a Transaction? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-the-Referrer-Field-from-the-first-event-of-a/m-p/203596#M59132</link>
    <description>&lt;P&gt;I've broken my events up into transactions to determine whether a user purchased and subscribed, and once narrowed down, I am trying to extract the referrer field of the first event in the transaction. My search currently looks like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | transaction sessionId endswith=eventName=orderplaced | search eventName=subscription | stats first(referrer) as Referrer | top Referrer
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I am trying to get the referrer field of the first event, but first(referrer) doesn't seem to work. It returns an empty field for all transactions that are there. How do I access this? Thanks for the help!&lt;/P&gt;

&lt;P&gt;Best,&lt;BR /&gt;
F&lt;/P&gt;</description>
    <pubDate>Wed, 02 Sep 2015 16:50:55 GMT</pubDate>
    <dc:creator>faramarz</dc:creator>
    <dc:date>2015-09-02T16:50:55Z</dc:date>
    <item>
      <title>How to extract the Referrer Field from the first event of a Transaction?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-the-Referrer-Field-from-the-first-event-of-a/m-p/203596#M59132</link>
      <description>&lt;P&gt;I've broken my events up into transactions to determine whether a user purchased and subscribed, and once narrowed down, I am trying to extract the referrer field of the first event in the transaction. My search currently looks like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | transaction sessionId endswith=eventName=orderplaced | search eventName=subscription | stats first(referrer) as Referrer | top Referrer
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I am trying to get the referrer field of the first event, but first(referrer) doesn't seem to work. It returns an empty field for all transactions that are there. How do I access this? Thanks for the help!&lt;/P&gt;

&lt;P&gt;Best,&lt;BR /&gt;
F&lt;/P&gt;</description>
      <pubDate>Wed, 02 Sep 2015 16:50:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-the-Referrer-Field-from-the-first-event-of-a/m-p/203596#M59132</guid>
      <dc:creator>faramarz</dc:creator>
      <dc:date>2015-09-02T16:50:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract the Referrer Field from the first event of a Transaction?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-the-Referrer-Field-from-the-first-event-of-a/m-p/203597#M59133</link>
      <description>&lt;P&gt;In a transaction, fields become multivalued if they appear in more than one event within the transaction. Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; ... | transaction sessionId endswith=eventName=orderplaced 
| search eventName=subscription 
| eval Referrer = mvindex(referrer, 0)
| top Referrer
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This should give you the referrer from the first event in each transaction.&lt;/P&gt;</description>
      <pubDate>Wed, 02 Sep 2015 19:14:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-the-Referrer-Field-from-the-first-event-of-a/m-p/203597#M59133</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-09-02T19:14:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract the Referrer Field from the first event of a Transaction?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-the-Referrer-Field-from-the-first-event-of-a/m-p/203598#M59134</link>
      <description>&lt;P&gt;Can you post some sample events? Does the Referrer present in all events that constitutes a transaction OR just in the first event?&lt;/P&gt;</description>
      <pubDate>Wed, 02 Sep 2015 22:10:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-the-Referrer-Field-from-the-first-event-of-a/m-p/203598#M59134</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2015-09-02T22:10:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract the Referrer Field from the first event of a Transaction?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-the-Referrer-Field-from-the-first-event-of-a/m-p/203599#M59135</link>
      <description>&lt;P&gt;shows up in most events in the transaction. I thought of approaching with mvindex, and it seems to work best. &lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2015 04:56:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-the-Referrer-Field-from-the-first-event-of-a/m-p/203599#M59135</guid>
      <dc:creator>faramarz</dc:creator>
      <dc:date>2015-09-03T04:56:32Z</dc:date>
    </item>
  </channel>
</rss>

