You need to sign in to do that
Don't have an account?
Deanna Aaron 11
Update a field based on specific criteria missing in workflow?
I’m setting up an automatic “Thank You” email that will send to our donors when an opportunity closes.
The workflow rule refers to specific criteria.
Examples:
If a user checks the box, the email will only send to the donor IF all of the criteria have been met.
If all of the criteria hasn’t been met, I can create a workflow rule/process builder to insert a value in a new field that I’m going to create, indicating which criteria hasn’t been met.
For example:
IF “Email Permission” box is checked AND the primary contact email IS BLANK, update field to:
Primary contact email is blank
What I’m wondering is…if multiple criteria are not met – how would I know?
Maybe we can append values or maybe there’s another solution?
Thank you for your help.
The workflow rule refers to specific criteria.
Examples:
- IF the primary contact email IS NOT BLANK
- IF the opportunity is less than or equal to $250
- IF the stage equals “posted”
If a user checks the box, the email will only send to the donor IF all of the criteria have been met.
If all of the criteria hasn’t been met, I can create a workflow rule/process builder to insert a value in a new field that I’m going to create, indicating which criteria hasn’t been met.
For example:
IF “Email Permission” box is checked AND the primary contact email IS BLANK, update field to:
Primary contact email is blank
What I’m wondering is…if multiple criteria are not met – how would I know?
Maybe we can append values or maybe there’s another solution?
Thank you for your help.
Instead of Field update using workflow, you can go with formula field,
Create a Formula field with Text data type and use 'if' condition to return the values.
Eg: if(isblank(primary_contact__c), 'Primary contact email is blank','')
+'&'+if(stage != 'posted' , 'stage is not equal to Posted','')
+'&'+if(NOT(amount <= 250 ), 'Amount is not less than or equal to $250','')
Result : If all the creteria is not satisfied, than
Primary contact email is blank & stage is not Posted & Amount is not less than or equal to $250,
if anyone of the creteria is not satisfied, then respective values will shown
Thanks.
If it helps you, please mark is as best answer, so it will be helpful for other developers.
All Answers
Instead of Field update using workflow, you can go with formula field,
Create a Formula field with Text data type and use 'if' condition to return the values.
Eg: if(isblank(primary_contact__c), 'Primary contact email is blank','')
+'&'+if(stage != 'posted' , 'stage is not equal to Posted','')
+'&'+if(NOT(amount <= 250 ), 'Amount is not less than or equal to $250','')
Result : If all the creteria is not satisfied, than
Primary contact email is blank & stage is not Posted & Amount is not less than or equal to $250,
if anyone of the creteria is not satisfied, then respective values will shown
Thanks.
If it helps you, please mark is as best answer, so it will be helpful for other developers.
1. How do I use this for picklist condition?
For example, I used: +'&'+if(NOT(ISPICKVAL(StageName, "Posted")), "Stage is Not Posted")
Received Syntax Issue---
Error: Incorrect number of parameters for function 'if()'. Expected 3, received 2
2. Is there a way to only generate the text in my formula field if a checkbox field is checked?
Thank you, again. You have helped us a lot!
1. IF statement contains 3 statements, Syntax: IF(Condititon, TRUE, FALSE).
Try out this : +'&'+if(NOT(ISPICKVAL(StageName, 'Posted')), 'Stage is Not Posted','')
2. Yes, IF( checkboxField__c, 'Values for TRUE', 'Values for FALSE')
Thanks,