Hi Can you guys help me with the code I am trying to give validation for the condition so for Add client Dropdown there should be only one active status if same occurs it should throw an validation error.
The issue is I tried using whercontains but add client and is active ....data type are different so it is not working
Discussion posts and replies are publicly visible
Why not you give the validation on the Active columns?
I want to compare both Active and Add client coulmn we can have many add client but for that is active column should be one
HI balajib2642,
you can try "AND" condition, in which in one contains func you can check for client and in other you can check for Active one. If both are true, then you can provide validation message.
We have to use wherecontains() only, the logic needs to be like as below. If you experience data type different error on contains() / wherecontains() fucmtion try casting with tostring, touniforstring, tointeger, etc... functions..
Logic:
if( count( wherecontains( "Active", touniformstring( index( local!data.status, wherecontains(fv!item.type, local!data.type), {} ) ) ) ) > 1, "Only one Active row allowed for each Type", "" )
balajib2642 said:....data type are different so it is not working
When you say something like this, you really also need to include details as to what you mean by "not working" (including the code you're currently trying, not just a screenshot of the grid, as well as the error message you get).
Because in cases like this, the answer we give could be anything ranging from a slight tweak to help correct a data type casting issue required by a finnicky comparison rule (common in Appian), or a total rewrite of your logic to produce something that works better over-all.