Legacy Dev Forum Posts

 View Only

Sign Up

Email rule to cater for case sensitivity

  • 1.  Email rule to cater for case sensitivity

    Posted 06-05-2025 19:16

    Mpho_Mashau | 2024-03-24 17:45:30 UTC | #1

    Hi There,

    How can I can make the below expression to be case insensitive and just match the wording?

    If (IsSet(EmailAddressLocalPart(Email.Message.from)), Contains(EmailAddressLocalPart(Email.Message.from), "MPSA.MASDRA"), false) and If(IsSet(EmailAddressDomainPart(Email.Message.from)), Contains(EmailAddressDomainPart(Email.Message.from), "WXCRTCT.TECH"), false)

    The assistance will be highly appreciated.

    Regards


    Jerome.Saint-Marc | 2024-03-25 10:00:59 UTC | #2

    Hello,

    You can use Upper function to convert a String to uppercase characters, and then compare with your value (in uppercase). Like: Contains(Upper(EmailAddressLocalPart(Email.Message.from)), "MPSA.MASDRA"), false)

    Or even (the second Upper on MPSA.MASDRA is just to cover cases where someone would modify this value and forget to set it in uppercase): Contains(Upper(EmailAddressLocalPart(Email.Message.from)), Upper("MPSA.MASDRA")), false)

    Regards,


    Mpho_Mashau | 2024-03-27 10:12:52 UTC | #3

    Great, thank you Jerome, your suggestion works perfectly.


    system | 2024-04-27 10:13:19 UTC | #4

    This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.


    This post was migrated from the old Developer Forum.

    ref: 25384