Hello people, I have a custom list field with valu...
# general
a
Hello people, I have a custom list field with values like T10, T20, T30. I want to create another field which gets populated with a formula. The formula should subtract the first character of list field value and set that as a value for formula field. Can anyone give me an idea on how to achieve that?
e
You can use text formula
SUBSTR({my_other_field}, 0, 1)
a
my_other_field in this case is a list of free-form-text values. I am trying this but it doesn't work. Do you have any idea what am I doing wrong?
e
So
my_other_field
is a single selected option field in the transaction? Or the whole list?
a
my_other_field is a whole list with 10 values in it. All those values have different ids
e
Let's say the whole and complete list is T10 T20 T30 Whats the expected output in the formula?
a
10,20,30 I think I did not put my question correctly. Sorry about that.
e
Originally I was thinking about using the native set up in the Transaction Body definition, where you set it in Validation & Defaulting > Default Value, Formula But in your use case, it's not possible You would need to use a Script that creates a search o query for all the values in the list, do the substring function, then concat the results, then setValue on the field.
a
I wanted to avoid the scripts but It seems like the only way.
Thank You.