function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
jordanmjordanm 

Possible bug with new flow text validation feature

Hello,

In my flow I have a form_SSN textbox and a form_SSN_Status radiolist

 

here is my validation routine for the form_SSN textbox:

 

NOT(
OR(
  NOT(
  OR (
  ISBLANK({!form_SSN}), 
  REGEX( {!form_SSN} , "[0-9]{9}"))),
AND (
  OR (
  {!form_SSN_Status} = "Verified",
  {!form_SSN_Status} = "Unverified"),
  ISBLANK({!form_SSN})),
AND (
  OR (
  {!form_SSN_Status} = "Refused",
  {!form_SSN_Status} = "Pending",
  {!form_SSN_Status} = "Unavailable"),
  NOT ISBLANK({!form_SSN})
)
)
)

 

When I select status "verified" or "unverified" I should be getting an error message if I attempt to not enter anything into SSN textbox, however, this is not the case.

The inverse is true, when I select the other statuses and have any value in the textbox the NOT ISBLANK({!field}) function DOES fire an error. This leads me to believe that this is a bug.

 

NOTE: I have this very same validation routine working as a validation rule on the object level... the only difference is I enclosed everything here with a NOT ( ) because validation rules shoot errors on "true" whereas flow validation errors out on "false".

 

 

 

 

jordanmjordanm

here is another illustration of the same problem, this time using ISNULL instead of ISBLANK

 

once again, when I select Income_Frequency "Anually" this validation should force me to enter values into Form_Amount_1 and Form_Date_1 but it does not.

 

NOT(
AND(
{!form_Income_Frequency} = "Annually",
OR(
ISNULL({!form_Amount_1}),
ISNULL({!form_Date_1})
)
)
)

RajaramRajaram

Try replacing the choice stored value by the merge field of the choice itself

 

So replace this:

{!form_SSN_Status} = "Verified"

 

with something like this:

{!form_SSN_Status} == {!choice_Verified},

jordanmjordanm

Not sure how, SSN_Status is a picklist(or in the flow, a form radio chocie list) that i make a dynamic choice for(which is how all the Verified, unverified, etc values are filled in). I don't have the individual choices of the picklist in any sort of referencable object, unless I'm missing something?

RajaramRajaram

Ah so the Radio list is a dynamic choice. Can you try to use the label instead of the stored value just for the that picklist field( Not for static choice) and try?

jordanmjordanm

Thanks for the feedback Raj,

 

Unfortunately, my SSN status Choice Label and Choice Stored Value are both Description__c

 

I do have a ticket pending with support on this issue also.

Frank_KFrank_K

Hi Jordan, did you hear back on the case by chance? I'm running into the same issue trying to use ISBLANK in a flow validation.

 

Thanks,
Frank

jordanmjordanm

Frank, It just got escalated to a T2 premier support guy, I'll post when I hear of a solution. I am still reasonably sure that this is a bug.

jordanmjordanm

T2 support confirmed the issue, he is forwarding it to T3 team to see if it is a known issue.

Frank_KFrank_K

Hi Jordan,

Thanks for the update. Hopefully this has already been addressed in Summer '12. I tried to check in a dev preview I have access to, but flows aren't available there yet. If I find out more, I'll post here.


Frank

ShadowSight1ShadowSight1

I've been running into the same problem - needing to make a field required depending on the value provided for a different field. 

 

Using your field names, the way I've set up my screen is that the validation rule exists on form_Amount_1 and form_Date_1.  What I've found is that if no data is entered into a field, the system doesn't run validation on it.  If I enter something into form_Amount_1, the validation rule runs and if form_Income_Frequency is set to "Anually", I get the validation error on form_Amount_1.

 

This works if I prefill the field and leave it as the default, but if I clear that field out while running through the flow... validation isn't run and no error shows up.

 

If I put the formula on form_Income_Frequency, it works, but then I have an error message showing up on that field telling you to fill out a different field.

 

Did support give you any workarounds?

jordanmjordanm

Long story short, they confirmed the problem in flow validation and said there were be no plans to fix it. It is one of the reasons I gave up flows completely and just made apex/VF wizards.