How to handle obsolete valid value

hi there

In one of the apps I developed, there was a need to have a field (let’s say communication method) that is mandatory.
The value was selected from a list of valid values (phone, SMS, email) using validIf definition that is looking up a table of valid values.
Now after the system is used for a long time, one of those valid values became obsolete (for example, SMS is not a valid option anymore).
But the requirement is to still keep SMS value in old rows having this value selected before the removal.

I have removed this valid value from the valid values reference table.

The issue now is that when the user edits an entry having the old value, he is requested to change the value to a valid one. The edit cannot be submitted without changing to a different method.

Any advice on how to do this?

Solved Solved
0 4 237
1 ACCEPTED SOLUTION

I managed to make it work this option: Methods[Method] + LIST([Method])
This is inspired by an answer by @Steve I saw where he was subtracting lists:

So I thought about adding the current value as valid value, and it worked.

Thanks @Steve

View solution in original post

4 REPLIES 4

Bahbus
New Member

IF([option]=“SMS”, TRUE, your current expression)

Thank you.
My current expression looks like this: Methods[Method].
I tried your suggestion but got the following message:
“IF function is used incorrectly:the second input (if-result) and third input(else-result) should have the same type.”

Ah, I see.

I was just going to correct my expression to be: IFS([_THIS]<>“SMS”, Methods[Method]) should also do the trick.

I managed to make it work this option: Methods[Method] + LIST([Method])
This is inspired by an answer by @Steve I saw where he was subtracting lists:

So I thought about adding the current value as valid value, and it worked.

Thanks @Steve

Top Labels in this Space