<?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 Reference a regex from a source tyoe in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Reference-a-regex-from-a-source-tyoe/m-p/400142#M71270</link>
    <description>&lt;P&gt;We have a dozen logs to ingest into Splunk. The log data will be obtained using regular expressions. Based on local conventions, we'll be creating a dozen source types, each named for its corresponding log.&lt;/P&gt;

&lt;P&gt;As it turns out, only two regular expressions are needed for the dozen logs, one regular expression for 4 of the logs, and the second regular expression for the other 8 logs. &lt;/P&gt;

&lt;P&gt;I don't want to copy and paste the one regular expression into 4 of the source types and the other regular expression into the other 8 source types. Instead, I want to store the two regular expressions in Splunk one time each and then reference each of the two regular expressions from the 12 source types as appropriate. &lt;/P&gt;

&lt;P&gt;Is there a way to store the regular expressions in Splunk one time each and then reference them from the 12 source types?&lt;/P&gt;</description>
    <pubDate>Thu, 30 May 2019 18:09:42 GMT</pubDate>
    <dc:creator>williamcharlton</dc:creator>
    <dc:date>2019-05-30T18:09:42Z</dc:date>
    <item>
      <title>Reference a regex from a source tyoe</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Reference-a-regex-from-a-source-tyoe/m-p/400142#M71270</link>
      <description>&lt;P&gt;We have a dozen logs to ingest into Splunk. The log data will be obtained using regular expressions. Based on local conventions, we'll be creating a dozen source types, each named for its corresponding log.&lt;/P&gt;

&lt;P&gt;As it turns out, only two regular expressions are needed for the dozen logs, one regular expression for 4 of the logs, and the second regular expression for the other 8 logs. &lt;/P&gt;

&lt;P&gt;I don't want to copy and paste the one regular expression into 4 of the source types and the other regular expression into the other 8 source types. Instead, I want to store the two regular expressions in Splunk one time each and then reference each of the two regular expressions from the 12 source types as appropriate. &lt;/P&gt;

&lt;P&gt;Is there a way to store the regular expressions in Splunk one time each and then reference them from the 12 source types?&lt;/P&gt;</description>
      <pubDate>Thu, 30 May 2019 18:09:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Reference-a-regex-from-a-source-tyoe/m-p/400142#M71270</guid>
      <dc:creator>williamcharlton</dc:creator>
      <dc:date>2019-05-30T18:09:42Z</dc:date>
    </item>
    <item>
      <title>Re: Reference a regex from a source tyoe</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Reference-a-regex-from-a-source-tyoe/m-p/400143#M71271</link>
      <description>&lt;P&gt;Simply: yes, you're looking for &lt;A href="https://docs.splunk.com/Documentation/Splunk/7.2.6/Knowledge/AboutSplunkregularexpressions#Modular_regular_expressions"&gt;modular regular expressions&lt;/A&gt;. &lt;/P&gt;

&lt;P&gt;Skalli&lt;/P&gt;</description>
      <pubDate>Mon, 03 Jun 2019 06:16:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Reference-a-regex-from-a-source-tyoe/m-p/400143#M71271</guid>
      <dc:creator>skalliger</dc:creator>
      <dc:date>2019-06-03T06:16:28Z</dc:date>
    </item>
  </channel>
</rss>

