How to check if contact's email address is not empty in process definition?

Hello devs,


I have a process definition to send an automated email to the specified contacts if certain conditions are fulfilled. I have been receiving a lot of exceptions in my sugar log regarding the email address missing while attempting to send an email. I need to know a way to eliminate contacts without an email address. I couldn't find the email field for selection in the process definition. Please help.


Regards.
Hatim

Parents
  • Hello  

    To address the situation, you could implement a flag system to indicate whether a Contact possesses an email address.
    Here's a step-by-step approach to achieve this:

    1 - Create a Checkbox Field:

    In Studio, create a calculated checkbox field in the Contacts module named "hasemailaddress_c"  with the following formula 

    not(equal(related($email_addresses,"email_address"),""))


    2 - Utilize the Checkbox in Your Process Definition:

    After saving the checkbox field, incorporate it within your Process Definition.
    Specifically, you can use it in an exclusive gateway to filter out Contacts that do not have an email address.




    Let me know if this helps. 

    André 

Reply
  • Hello  

    To address the situation, you could implement a flag system to indicate whether a Contact possesses an email address.
    Here's a step-by-step approach to achieve this:

    1 - Create a Checkbox Field:

    In Studio, create a calculated checkbox field in the Contacts module named "hasemailaddress_c"  with the following formula 

    not(equal(related($email_addresses,"email_address"),""))


    2 - Utilize the Checkbox in Your Process Definition:

    After saving the checkbox field, incorporate it within your Process Definition.
    Specifically, you can use it in an exclusive gateway to filter out Contacts that do not have an email address.




    Let me know if this helps. 

    André 

Children