<?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: Combine multiple Regex rules into single search query in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-combine-multiple-regex-rules-into-single-search-query/m-p/621652#M216084</link>
    <description>&lt;LI-CODE lang="markup"&gt;index=myindex sourcetype=my-app:app |spath message | regex message="Error while creating account|api-down|Error while updating trial account|JWT Token creation failed with error|Error while fetching IPLookU"&lt;/LI-CODE&gt;</description>
    <pubDate>Tue, 22 Nov 2022 07:56:37 GMT</pubDate>
    <dc:creator>ITWhisperer</dc:creator>
    <dc:date>2022-11-22T07:56:37Z</dc:date>
    <item>
      <title>How to combine multiple regex rules into single search query?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-combine-multiple-regex-rules-into-single-search-query/m-p/621647#M216081</link>
      <description>&lt;P&gt;I have the following search queries:&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;
&lt;LI-CODE lang="markup"&gt;API Error Alert
---------------
index=myindex sourcetype=my-app:app |spath message | regex message="^.*Error while creating account.*$" |dedup my_id_field

API Down Alert
---------------
index=myindex sourcetype=my-app:app | spath message | regex message="^.*api-down.*$" | dedup my_id_field

Update API Error
------------------
index=myindex sourcetype=my-app:app | spath message | regex message="^.*Error while updating trial account.*$" | dedup my_id_field&lt;/LI-CODE&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;
&lt;P&gt;&amp;nbsp;I have some more of the same kind. It is checking against multiple messages using. regular expressions. Now I would like to create an email alert for all these events and would like combine all these into one query and so I can create a single alert rather than creating individual alerts. How can I combine these queries ? It should trigger the email alert if any of these conditions is true. I have tried the following, but it is not working.&amp;nbsp;&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;
&lt;LI-CODE lang="markup"&gt;index=myindex sourcetype=my-app:app |spath message | regex message="^.*Error while creating account.*$" | regex message="^.*api-down.*$"|regex message="^.*Error while updating trial account.*$" |regex message="^.*JWT Token creation failed with error.*$" |regex message="^.*Error while fetching IPLookU.*$"&lt;/LI-CODE&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, 22 Nov 2022 14:30:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-combine-multiple-regex-rules-into-single-search-query/m-p/621647#M216081</guid>
      <dc:creator>alwinaugustin</dc:creator>
      <dc:date>2022-11-22T14:30:42Z</dc:date>
    </item>
    <item>
      <title>Re: Combine multiple Regex rules into single search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-combine-multiple-regex-rules-into-single-search-query/m-p/621648#M216082</link>
      <description>&lt;P&gt;Use where clause rather than regex&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=myindex sourcetype=my-app:app
| spath message
| where match(message, "^.*Error while creating account.*$") OR
        match(message, "^.*api-down.*$") OR 
        match(message, "^.*Error while updating trial account.*$") OR
        match(message, "^.*JWT Token creation failed with error.*$") OR
        match(message, "^.*Error while fetching IPLookU.*$")
&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 22 Nov 2022 07:24:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-combine-multiple-regex-rules-into-single-search-query/m-p/621648#M216082</guid>
      <dc:creator>bowesmana</dc:creator>
      <dc:date>2022-11-22T07:24:57Z</dc:date>
    </item>
    <item>
      <title>Re: Combine multiple Regex rules into single search query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-combine-multiple-regex-rules-into-single-search-query/m-p/621652#M216084</link>
      <description>&lt;LI-CODE lang="markup"&gt;index=myindex sourcetype=my-app:app |spath message | regex message="Error while creating account|api-down|Error while updating trial account|JWT Token creation failed with error|Error while fetching IPLookU"&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 22 Nov 2022 07:56:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-combine-multiple-regex-rules-into-single-search-query/m-p/621652#M216084</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-11-22T07:56:37Z</dc:date>
    </item>
  </channel>
</rss>

