I have a Record Related Action Visibility question. I am querying off of a Data

I have a Record Related Action Visibility question. I am querying off of a Data Store Entity, and pulling in a field called Status (Type: Text). I am trying to use this Status field to evaluate the Visibility for the Related Action. Example: if( rf!status = "Complete", true, false). I have tried multiple variations of this if statement (toboolean(if( rf!status = "Complete", true, false)) - if( rf!status = "Complete", true(), false()) and many others. Nothing seems to be evaluating to true, causing the visibility of the related action not to appear. I have tried evaluating with a Boolean field I am pulling from the Data Store Entity, and it seems to be working fine. Is there anyway to evaluate a text field to allow visibility to work for a related action?

OriginalPostID-154938

OriginalPostID-154938

  Discussion posts and replies are publicly visible

Parents
  • @brianc Hi, what you have done is perfectly correct according to my knowledge as well as experience. Especially our team has seen this issue many times and we weren't able to find the exact problem unfortunately. In order to resolve this, we have been taking various approaches such as casting the value to single type (Let's say you have queried a single record from database, you may think that you are retrieving only one record, but when you start using it in the subsequent steps, it behaves like an array and gives unpredictable results when you are in RA rules, but the same works fine everywhere else) when we query database or casting the value to boolean of single type.

    One thing I could definitely say according to our team's experience is, the area in which we write related action visibility rules is very much sensitive and behaving in an unusual manner which I can't elaborate as of now (because the rule perfectly works if it is used in an sail interface or script task or expression etc, but the same rule starts behaving differently when it comes to visibility of RA), but yes we are facing some issues and opting for different ways for resolving the issue each time.

    If you can attach the code snippet, probably myself or other Appian practitioners who commented above can help you in resolving this.
Reply
  • @brianc Hi, what you have done is perfectly correct according to my knowledge as well as experience. Especially our team has seen this issue many times and we weren't able to find the exact problem unfortunately. In order to resolve this, we have been taking various approaches such as casting the value to single type (Let's say you have queried a single record from database, you may think that you are retrieving only one record, but when you start using it in the subsequent steps, it behaves like an array and gives unpredictable results when you are in RA rules, but the same works fine everywhere else) when we query database or casting the value to boolean of single type.

    One thing I could definitely say according to our team's experience is, the area in which we write related action visibility rules is very much sensitive and behaving in an unusual manner which I can't elaborate as of now (because the rule perfectly works if it is used in an sail interface or script task or expression etc, but the same rule starts behaving differently when it comes to visibility of RA), but yes we are facing some issues and opting for different ways for resolving the issue each time.

    If you can attach the code snippet, probably myself or other Appian practitioners who commented above can help you in resolving this.
Children
No Data