<?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 Multivalue Field extaction using Regular Expressions in Splunk Enterprise</title>
    <link>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518319#M3286</link>
    <description>&lt;P&gt;I'm trying to extract fields from the following event data&lt;/P&gt;&lt;P&gt;[Scenario_summary]&lt;BR /&gt;Scenario Type=Manual Scenario&lt;BR /&gt;Goal Profile Name=Schedule 1&lt;BR /&gt;Mode=Scenario Scheduling&lt;BR /&gt;Scenario Duration=Start 27 Vusers: 1 every 00:00:15 (HH:MM:SS); Run for 00:30:00 (HH:MM:SS); Stop all Vusers simultaneously&lt;BR /&gt;Load Behavior=Initialize each Vuser just before it runs&lt;/P&gt;&lt;P&gt;[Scripts]&lt;BR /&gt;apache_on_5154=D:\LoadRunner Repo\LoadRunner\Loadrunner Scripts\apache_on_5154\apache_on_5154.usr&lt;BR /&gt;AjaxClickAndScript1=D:\LoadRunner Scripts\SPLUNK_SOLUTION_2\AjaxClickAndScript1\AjaxClickAndScript1.usr&lt;BR /&gt;AddNewCustomer=D:\CPE_Demo\AddNewCustomer\AddNewCustomer.usr&lt;/P&gt;&lt;P&gt;[Scripts_types]&lt;BR /&gt;apache_on_5154=Multi+QTWeb&lt;BR /&gt;AjaxClickAndScript1=WebAjax&lt;BR /&gt;AddNewCustomer=Multi+QTWeb&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Specifically I want to extract the LoadRunner group names and protocols below the [Scripts_types] which can be 1 to n depending on the Scenerio.&amp;nbsp; In this example the script names would be&lt;/P&gt;&lt;P&gt;apache_on_5154&lt;BR /&gt;AjaxClickAndScript1&lt;BR /&gt;AddNewCustomer&lt;/P&gt;&lt;P&gt;I've tried a regular expression with a named group to extract the fields. eg&lt;/P&gt;&lt;P&gt;\[Scripts_types\]\n(?&amp;lt;Group1&amp;gt;.+)=.+&lt;BR /&gt;\[Scripts_types\]\n(?:.+)=.+\n(?&amp;lt;Group2&amp;gt;.+)=.+\n(?:.+)=.+&lt;BR /&gt;\[Scripts_types\]\n(?:.+)=.+\n(?:.+)=.+\n(?&amp;lt;Group3&amp;gt;.+)=.+&lt;/P&gt;&lt;P&gt;But that gives me 3 different named fields and does not cater for case where there are more of less of these lines in the event.&amp;nbsp;&lt;/P&gt;&lt;P&gt;If I use a repeating group like&lt;/P&gt;&lt;P&gt;\[Scripts_types\](\n(?&amp;lt;GroupName&amp;gt;.+)=.+)+&lt;/P&gt;&lt;P&gt;It only captures the last iteration ie "AddNewCustomer"&amp;nbsp;&lt;/P&gt;&lt;P&gt;Anyone know how to deal with this?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 08 Sep 2020 02:28:50 GMT</pubDate>
    <dc:creator>perrinj2</dc:creator>
    <dc:date>2020-09-08T02:28:50Z</dc:date>
    <item>
      <title>Multivalue Field extaction using Regular Expressions</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518319#M3286</link>
      <description>&lt;P&gt;I'm trying to extract fields from the following event data&lt;/P&gt;&lt;P&gt;[Scenario_summary]&lt;BR /&gt;Scenario Type=Manual Scenario&lt;BR /&gt;Goal Profile Name=Schedule 1&lt;BR /&gt;Mode=Scenario Scheduling&lt;BR /&gt;Scenario Duration=Start 27 Vusers: 1 every 00:00:15 (HH:MM:SS); Run for 00:30:00 (HH:MM:SS); Stop all Vusers simultaneously&lt;BR /&gt;Load Behavior=Initialize each Vuser just before it runs&lt;/P&gt;&lt;P&gt;[Scripts]&lt;BR /&gt;apache_on_5154=D:\LoadRunner Repo\LoadRunner\Loadrunner Scripts\apache_on_5154\apache_on_5154.usr&lt;BR /&gt;AjaxClickAndScript1=D:\LoadRunner Scripts\SPLUNK_SOLUTION_2\AjaxClickAndScript1\AjaxClickAndScript1.usr&lt;BR /&gt;AddNewCustomer=D:\CPE_Demo\AddNewCustomer\AddNewCustomer.usr&lt;/P&gt;&lt;P&gt;[Scripts_types]&lt;BR /&gt;apache_on_5154=Multi+QTWeb&lt;BR /&gt;AjaxClickAndScript1=WebAjax&lt;BR /&gt;AddNewCustomer=Multi+QTWeb&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Specifically I want to extract the LoadRunner group names and protocols below the [Scripts_types] which can be 1 to n depending on the Scenerio.&amp;nbsp; In this example the script names would be&lt;/P&gt;&lt;P&gt;apache_on_5154&lt;BR /&gt;AjaxClickAndScript1&lt;BR /&gt;AddNewCustomer&lt;/P&gt;&lt;P&gt;I've tried a regular expression with a named group to extract the fields. eg&lt;/P&gt;&lt;P&gt;\[Scripts_types\]\n(?&amp;lt;Group1&amp;gt;.+)=.+&lt;BR /&gt;\[Scripts_types\]\n(?:.+)=.+\n(?&amp;lt;Group2&amp;gt;.+)=.+\n(?:.+)=.+&lt;BR /&gt;\[Scripts_types\]\n(?:.+)=.+\n(?:.+)=.+\n(?&amp;lt;Group3&amp;gt;.+)=.+&lt;/P&gt;&lt;P&gt;But that gives me 3 different named fields and does not cater for case where there are more of less of these lines in the event.&amp;nbsp;&lt;/P&gt;&lt;P&gt;If I use a repeating group like&lt;/P&gt;&lt;P&gt;\[Scripts_types\](\n(?&amp;lt;GroupName&amp;gt;.+)=.+)+&lt;/P&gt;&lt;P&gt;It only captures the last iteration ie "AddNewCustomer"&amp;nbsp;&lt;/P&gt;&lt;P&gt;Anyone know how to deal with this?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Sep 2020 02:28:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518319#M3286</guid>
      <dc:creator>perrinj2</dc:creator>
      <dc:date>2020-09-08T02:28:50Z</dc:date>
    </item>
    <item>
      <title>Re: Multivalue Field extaction using Regular Expressions</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518329#M3287</link>
      <description>&lt;P&gt;is below only one event ? if yes, please don't format the event before sharing it in community especially the question is about regular expression, we can't give proper answer if the event is modified and shared here.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;[Scenario_summary]&lt;BR /&gt;Scenario Type=Manual Scenario&lt;BR /&gt;Goal Profile Name=Schedule 1&lt;BR /&gt;Mode=Scenario Scheduling&lt;BR /&gt;Scenario Duration=Start 27 Vusers: 1 every 00:00:15 (HH:MM:SS); Run for 00:30:00 (HH:MM:SS); Stop all Vusers simultaneously&lt;BR /&gt;Load Behavior=Initialize each Vuser just before it runs&lt;/P&gt;&lt;P&gt;[Scripts]&lt;BR /&gt;apache_on_5154=D:\LoadRunner Repo\LoadRunner\Loadrunner Scripts\apache_on_5154\apache_on_5154.usr&lt;BR /&gt;AjaxClickAndScript1=D:\LoadRunner Scripts\SPLUNK_SOLUTION_2\AjaxClickAndScript1\AjaxClickAndScript1.usr&lt;BR /&gt;AddNewCustomer=D:\CPE_Demo\AddNewCustomer\AddNewCustomer.usr&lt;/P&gt;&lt;P&gt;[Scripts_types]&lt;BR /&gt;apache_on_5154=Multi+QTWeb&lt;BR /&gt;AjaxClickAndScript1=WebAjax&lt;BR /&gt;AddNewCustomer=Multi+QTWeb&lt;/P&gt;</description>
      <pubDate>Tue, 08 Sep 2020 04:02:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518329#M3287</guid>
      <dc:creator>thambisetty</dc:creator>
      <dc:date>2020-09-08T04:02:34Z</dc:date>
    </item>
    <item>
      <title>Re: Multivalue Field extaction using Regular Expressions</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518330#M3288</link>
      <description>&lt;P&gt;It's one event&lt;/P&gt;</description>
      <pubDate>Tue, 08 Sep 2020 04:04:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518330#M3288</guid>
      <dc:creator>perrinj2</dc:creator>
      <dc:date>2020-09-08T04:04:24Z</dc:date>
    </item>
    <item>
      <title>Re: Multivalue Field extaction using Regular Expressions</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518334#M3289</link>
      <description>&lt;P&gt;Further to this&amp;nbsp; the following regex&amp;nbsp;&lt;/P&gt;&lt;P&gt;\[Scripts_types\](?&amp;lt;Scripts_types&amp;gt;(?:\n(?:.+)=.+)+)&lt;/P&gt;&lt;P&gt;will extract a single named group with value&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;apache_on_5154=Multi+QTWeb AjaxClickAndScript1=WebAjax AddNewCustomer=Multi+QTWeb&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;which I think is the only regex that makes sense in this situation.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;So I'll look at how to extract the required fields from the field values. Any tips on this approach appreciated.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Sep 2020 04:36:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518334#M3289</guid>
      <dc:creator>perrinj2</dc:creator>
      <dc:date>2020-09-08T04:36:01Z</dc:date>
    </item>
    <item>
      <title>Re: Multivalue Field extaction using Regular Expressions</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518370#M3298</link>
      <description>&lt;P&gt;Having got a single field, can you not run a further regex on that to get just the data you require?&lt;/P&gt;</description>
      <pubDate>Tue, 08 Sep 2020 07:06:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518370#M3298</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2020-09-08T07:06:11Z</dc:date>
    </item>
    <item>
      <title>Re: Multivalue Field extaction using Regular Expressions</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518579#M3340</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp; Thanks, that's what I thought might be the next step. I was hoping to do it in one pass but that doesn't seem possible.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Sep 2020 23:26:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Multivalue-Field-extaction-using-Regular-Expressions/m-p/518579#M3340</guid>
      <dc:creator>perrinj2</dc:creator>
      <dc:date>2020-09-08T23:26:40Z</dc:date>
    </item>
  </channel>
</rss>

