<?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 Extract field across multiple sources in different context in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Extract-field-across-multiple-sources-in-different-context/m-p/448536#M127080</link>
    <description>&lt;P&gt;Hello Splunkers,&lt;/P&gt;

&lt;P&gt;I need some help with a basic extraction.  I have about 8 different styles of logs which have the same event format.  I brought them all in with the same sourcetype.&lt;BR /&gt;
The first logs "Processing.log" have a transaction ID in the following format:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Transaction ( 12345 )
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The next log "Initiator" has the ID in the following format:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;03/14/2019 18:11:53.392-&amp;gt; Level:8, ( 987654321, 21, 0, *'12345'*, null, TO_DATE('2019/03/01 00:00:00','YYYY/MM/DD
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The next log includes it in the following event contexts:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Not included because custom value doesn't match: transaction: 12345
03/14/2019 18:10:12.685-&amp;gt; Level:8, Fixing transaction Id 12345
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I want to extract all these events as a single field "Transaction".  I thought I could do it with a "OR" (|) in regex but it's not working:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;(?:Transaction\s\(\s|transaction\:\s|transaction\sId\s|100.)(?P&amp;lt;transaction&amp;gt;\d{4,5})
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Thanks for your guidance!&lt;/P&gt;</description>
    <pubDate>Mon, 18 Mar 2019 15:40:58 GMT</pubDate>
    <dc:creator>johnansett</dc:creator>
    <dc:date>2019-03-18T15:40:58Z</dc:date>
    <item>
      <title>Extract field across multiple sources in different context</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-field-across-multiple-sources-in-different-context/m-p/448536#M127080</link>
      <description>&lt;P&gt;Hello Splunkers,&lt;/P&gt;

&lt;P&gt;I need some help with a basic extraction.  I have about 8 different styles of logs which have the same event format.  I brought them all in with the same sourcetype.&lt;BR /&gt;
The first logs "Processing.log" have a transaction ID in the following format:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Transaction ( 12345 )
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The next log "Initiator" has the ID in the following format:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;03/14/2019 18:11:53.392-&amp;gt; Level:8, ( 987654321, 21, 0, *'12345'*, null, TO_DATE('2019/03/01 00:00:00','YYYY/MM/DD
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The next log includes it in the following event contexts:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Not included because custom value doesn't match: transaction: 12345
03/14/2019 18:10:12.685-&amp;gt; Level:8, Fixing transaction Id 12345
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I want to extract all these events as a single field "Transaction".  I thought I could do it with a "OR" (|) in regex but it's not working:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;(?:Transaction\s\(\s|transaction\:\s|transaction\sId\s|100.)(?P&amp;lt;transaction&amp;gt;\d{4,5})
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Thanks for your guidance!&lt;/P&gt;</description>
      <pubDate>Mon, 18 Mar 2019 15:40:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-field-across-multiple-sources-in-different-context/m-p/448536#M127080</guid>
      <dc:creator>johnansett</dc:creator>
      <dc:date>2019-03-18T15:40:58Z</dc:date>
    </item>
    <item>
      <title>Re: Extract field across multiple sources in different context</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-field-across-multiple-sources-in-different-context/m-p/448537#M127081</link>
      <description>&lt;P&gt;Your regex looks ok to me (although i adjusted a bit for the second example)&lt;BR /&gt;
&lt;A href="https://regex101.com/r/sFjR1X/2"&gt;https://regex101.com/r/sFjR1X/2&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Mar 2019 15:50:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-field-across-multiple-sources-in-different-context/m-p/448537#M127081</guid>
      <dc:creator>nickhills</dc:creator>
      <dc:date>2019-03-18T15:50:44Z</dc:date>
    </item>
  </channel>
</rss>

