Mail forward rule with a pattern

Sig 41 Reputation points
2020-10-26T08:11:24.57+00:00

Hi there,

As a follow-up to https://answers.microsoft.com/en-us/msoffice/forum/msoffice_o365admin-mso_exchon-mso_o365b/office-365-atp-external-email-forwarding-controls/cb341834-3bc3-41f0-bd64-e366122d9f32?tm=1602489437427, I'm trying to create a mail forward rule using a pattern.

I need to apply the rules only in the subject starts with "SOP and contains Document Ready"

For instance, a mail having "SOP123 Document Ready" as a subject should trigger the rule. While a mail having "WIP123 Document Ready" as a subject should not trigger the rule.

I have looked at https://learn.microsoft.com/en-us/exchange/security-and-compliance/mail-flow-rules/use-rules-to-route-email#using-phrases-and-patterns-in-the-text-file and I have defined my rules as

35011-image.png

But the rule doesn't seem to be triggered.

Am I missing anything here? How should I define the pattern to be matched?

This is a follw-up of https://answers.microsoft.com/threadauth/6d448ced-b7a7-47c4-94eb-beb4dd546f88/messages/4f26d881-8a3f-4666-9868-3c4000ea7a50.

Thanks,
Sig

Exchange Exchange Server Management
0 comments No comments
{count} votes

Accepted answer
  1. Lucas Liu-MSFT 6,191 Reputation points
    2020-10-27T09:17:49.29+00:00

    Hi @Sig ,
    According to the information you provide, putting * directly into the regular expression will not express the role of wildcards.

    Please create a transport rule according to the following settings. This rule will redirect emails with 35247-3333.png in the subject to your specified In the mailbox("*" can express any other character).

    The suject matches these text patterns: SOP.*?Document
    35392-22222.png

    ----------

    If the response is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


1 additional answer

Sort by: Most helpful
  1. Udara Peiris 701 Reputation points
    2020-10-26T08:51:22.01+00:00

    Add exception for WIP123 in that rule.

    Please refer following,
    https://learn.microsoft.com/en-us/exchange/security-and-compliance/mail-flow-rules/conditions-and-exceptions

    34920-1.jpg

    (If this answer id helpful, don't forget to mark it as accepted answer)

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.