<?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: How to use a rex field in another search in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-rex-field-in-another-search/m-p/548689#M155661</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;It did not work. I am still getting 0 results.&lt;/P&gt;</description>
    <pubDate>Tue, 20 Apr 2021 21:25:07 GMT</pubDate>
    <dc:creator>irvindominguezs</dc:creator>
    <dc:date>2021-04-20T21:25:07Z</dc:date>
    <item>
      <title>How to use a rex field in another search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-rex-field-in-another-search/m-p/548666#M155656</link>
      <description>&lt;P&gt;I am trying the following query. However, activityId is not being passed to the second query and I am not having any results.&lt;/P&gt;&lt;P&gt;index=kubernetes lineOfBusiness=ifm component=chub useCase=C5 responsePayload&lt;BR /&gt;| rex field=_raw "imsiActivationDate\"\:\"(?&amp;lt;imsiActivationDate&amp;gt;[^\"]*)"&lt;BR /&gt;| rex field=_raw "simChangeDate\"\:\"(?&amp;lt;simChangeDate&amp;gt;[^\"]*)"&lt;BR /&gt;| rex field=_raw "activity-id=(?&amp;lt;activityId&amp;gt;[^||]*)"&lt;BR /&gt;| table activityId | map search="index=kubernetes lineOfBusiness=ifm component=ifm activity-id=*$activityId$*" | rex field=_raw "msisdn":"=(?&amp;lt;msisdn&amp;gt;[^=]*)" | dedup activityId, msisdn&lt;BR /&gt;| table activityId msisdn&lt;/P&gt;</description>
      <pubDate>Tue, 20 Apr 2021 18:53:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-rex-field-in-another-search/m-p/548666#M155656</guid>
      <dc:creator>irvindominguezs</dc:creator>
      <dc:date>2021-04-20T18:53:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a rex field in another search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-rex-field-in-another-search/m-p/548686#M155660</link>
      <description>&lt;P&gt;hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225260"&gt;@irvindominguezs&lt;/a&gt;,&lt;BR /&gt;&lt;BR /&gt;Instead of using the &lt;STRONG&gt;map&lt;/STRONG&gt; command, you can use the first/main search as a &lt;STRONG&gt;sub search&lt;/STRONG&gt; to filter&amp;nbsp;&lt;SPAN&gt;&lt;STRONG&gt;activityId&lt;/STRONG&gt; in the second search.&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=kubernetes lineOfBusiness=ifm component=ifm activity-id IN([| search index=kubernetes lineOfBusiness=ifm component=chub useCase=C5 responsePayload | rex field=_raw "activity-id=(?&amp;lt;activityId&amp;gt;[^||]*)" | eval activityId="*".activityId."*" | stats values(activityId) as re | return $re]) | rex field=_raw "msisdn":"=(?&amp;lt;msisdn&amp;gt;[^=]*)" | dedup activityId, msisdn
| table activityId msisdn&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If this reply helps you, a like would be appreciated.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Apr 2021 21:13:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-rex-field-in-another-search/m-p/548686#M155660</guid>
      <dc:creator>manjunathmeti</dc:creator>
      <dc:date>2021-04-20T21:13:30Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a rex field in another search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-rex-field-in-another-search/m-p/548689#M155661</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;It did not work. I am still getting 0 results.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Apr 2021 21:25:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-rex-field-in-another-search/m-p/548689#M155661</guid>
      <dc:creator>irvindominguezs</dc:creator>
      <dc:date>2021-04-20T21:25:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to use a rex field in another search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-rex-field-in-another-search/m-p/548722#M155671</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225260"&gt;@irvindominguezs&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;Can you try below?&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=kubernetes lineOfBusiness=ifm component=chub useCase=C5 responsePayload
| rex field=_raw "imsiActivationDate\"\:\"(?&amp;lt;imsiActivationDate&amp;gt;[^\"]*)"
| rex field=_raw "simChangeDate\"\:\"(?&amp;lt;simChangeDate&amp;gt;[^\"]*)"
| rex field=_raw "activity-id=(?&amp;lt;activityId&amp;gt;[^||]*)"
| table activityId | map search="search index=kubernetes lineOfBusiness=ifm component=ifm activity-id=*$activityId$*" | rex field=_raw "msisdn":"=(?&amp;lt;msisdn&amp;gt;[^=]*)" | dedup activityId, msisdn
| table activityId msisdn&lt;/LI-CODE&gt;</description>
      <pubDate>Wed, 21 Apr 2021 05:49:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-use-a-rex-field-in-another-search/m-p/548722#M155671</guid>
      <dc:creator>scelikok</dc:creator>
      <dc:date>2021-04-21T05:49:14Z</dc:date>
    </item>
  </channel>
</rss>

