For anyone who will read this in the future, I just made the following learning:
According to the Airtable documentation "Array functions can only be used in rollup fields or when the input field is a lookup field."
This is misleading and not 100% correct. The lookup field's underlying field is a multi-select type, and ARRAYSLICE doesn't seem to work with this type.
ARRAYSLICE does work with text fields of lookup fields (e.g. name, etc.), and not other field types.
For anyone who will read this in the future, I just made the following learning:
According to the Airtable documentation "Array functions can only be used in rollup fields or when the input field is a lookup field."
This is misleading and not 100% correct. The lookup field's underlying field is a multi-select type, and ARRAYSLICE doesn't seem to work with this type.
ARRAYSLICE does work with text fields of lookup fields (e.g. name, etc.), and not other field types.
I found the solution, and I hope it helps everyone who faces the same issue.
We need to extract the values with REGEX. The formulas to extract the first, second, and last values are as follows:
Extract first value:
REGEX_EXTRACT(verticals_from_contact,"[^,]*")
REGEX_EXTRACT(verticals_from_contact,"(?:, )([^,]*)")
REGEX_EXTRACT(verticals_from_contact,"(?:?^,]*,){2}(}^,]*)")
Extract the last value:
REGEX_EXTRACT(verticals_from_contact,"c^,]*$")
I have no idea how this works, but after endless trial and error, it extracts the correct values for me.