Help

Re: Lookup text fields without comma separation

Solved
Jump to Solution
2386 2
cancel
Showing results for 
Search instead for 
Did you mean: 
Alan_Edwards
6 - Interface Innovator
6 - Interface Innovator

I’m noticing that when using Lookup fields to gather all the text from various related text fields, the output in the lookup field separates each of the resulting contents with a comma automatically. Here’s the situation:

1 - Contacts table contains a link to Interactions table.
2 - Each Interaction contains text meeting notes, which are concatenated in a separate field with the date of the meeting and a line break at the end.
3 - The Contacts table in turn has a lookup field which brings back all of those concatenated results, so that I can pull up a contact in gallery view and see something like this in their notes field:

2-22-2015: Met for first time at her office, talked about our basic services.

, 4-18-2017: Met with her whole team to set up launch.

So that comma in front of the 4 isn’t a type-o in this message; rather it’s the output I’m getting. Can I get that to go away?

1 Solution

Accepted Solutions
Justin_Barrett
18 - Pluto
18 - Pluto

Lookup fields return arrays, and commas are the default separator when displaying an array. In the lookup field itself, there’s no way to change that formatting. However, you could change the lookup to a rollup, which is effectively the same thing but with the addition of an aggregation formula. That would give you control over the display.

If I’m interpreting your message correctly…

You already have line breaks included in the interaction notes, hence the gap between those two lines. If that’s correct, you could use this for your aggregation formula:

ARRAYJOIN(values, "")

If you don’t have line breaks, you could add them with this aggregation formula:

ARRAYJOIN(values, "\n\n")

See Solution in Thread

4 Replies 4
Justin_Barrett
18 - Pluto
18 - Pluto

Lookup fields return arrays, and commas are the default separator when displaying an array. In the lookup field itself, there’s no way to change that formatting. However, you could change the lookup to a rollup, which is effectively the same thing but with the addition of an aggregation formula. That would give you control over the display.

If I’m interpreting your message correctly…

You already have line breaks included in the interaction notes, hence the gap between those two lines. If that’s correct, you could use this for your aggregation formula:

ARRAYJOIN(values, "")

If you don’t have line breaks, you could add them with this aggregation formula:

ARRAYJOIN(values, "\n\n")

YESSSSSSS! Thank you!

Glad to know that you got the answer you were seeking! If you would, please mark my comment above (not this one) as the solution to your question. This helps others who may be searching with similar questions. Thanks!

thanks for the tip - done!