You need to sign in to do that
Don't have an account?
Nick Valeriote
Flow Validation Rule To See if Field Value Already Exists
Hi SF Community,
I'm somewhat new to Flow, but managed to put together a Flow (with the help of this community) that allows users to click a button (Create SOW) on my Project__c object and fill in a screen that then creates an associated SOW record (SOW__c).
I have a Record Update element at the end of the Flow (see below screen shot) that grabs the SOW Name and adds it to a field called Related Account SOW on the associated project record.
I'm looking for a way (maybe a validation through another element) to check to see if a value already exists in the Related_Account_SOW__c field, and if it does, warn the user and don't let them save the record. We don't want them overwriting this field with a new SOW record if one already exists.
Any ideas?
Thanks!
Nick
I'm somewhat new to Flow, but managed to put together a Flow (with the help of this community) that allows users to click a button (Create SOW) on my Project__c object and fill in a screen that then creates an associated SOW record (SOW__c).
I have a Record Update element at the end of the Flow (see below screen shot) that grabs the SOW Name and adds it to a field called Related Account SOW on the associated project record.
I'm looking for a way (maybe a validation through another element) to check to see if a value already exists in the Related_Account_SOW__c field, and if it does, warn the user and don't let them save the record. We don't want them overwriting this field with a new SOW record if one already exists.
Any ideas?
Thanks!
Nick
All Answers
Happy to help again.
Using Current Flow
You would need to pass the said field as a variable in the initial URL itself by adding another variable "&RelAccSOW={!Project.Related_Account_SOW__c}", where RelAccSOW will be an input type variable with default value of "EmptyString" global constant.
Your Flow would start with a decision element validating if anything has come in the new varibale we just defined.
Condition1: New Screen with a message stating SOW already created and with just a Finish Button.
Condition2: Carry on with the current screen and Flow.
Hope this helps. Please mark as best answer if it does.
Cheers!!
Gaurav
However, it seems to work only for condition 1 (a SOW exists and the user can't go forward). When I test this out on a project that does not have a value in the Related Account SOW field, it still gives me the warning message I created for the decision condition that thinks a SOW record already exists for said project. Any ideas why this might be? Here's how I set it up:
Thanks.
I think you need to add another condition for each outcome here viz
Add the similar condition with is null false for the other outcome.
Hope this helps.
Cheers!!
Gaurav