JOIN

JOIN joins arguments with a provided delimiter argument. It can take an arbitrary number of optional arguments.

Function category: Text

Syntax

JOIN(arg1, arg2, [arg3])

Argument

Description

arg1

Delimiter used to join text.

arg2

String or array of strings.

arg3

Optional. Another string or array of strings.

Examples

Let's say we're given the following response that includes a list of car manufacturers for a given part:

{
"data": {
"parts": {
"part_1": [
"Toyota",
"Hyundai",
"Kia",
"Mercedes Benz"
],
"part_2": [
"BMW",
"Mercedes Benz",
"Ford",
"Tesla"
]
}
}
}

Example 1: Join list of items

If we want to create an easier to read version of the distributors for a given part, use the following function.

# Create a readable parts distributor list
JOIN(", " data.parts.part_1)
# Returns "Toyota, Hyundai, Kia, Mercedes Benz"

Example 2: Join multiple values

If we want to add the third optional argument to combine multiple values or arrays, use the following function.

# Create a readable parts list using multiple distributor lists
JOIN(", " data.parts.part_1, data.parts.part_2)
# Returns "Toyota, Hyundai, Kia, Mercedes Benz, BMW, Mercedes Benz, Ford, Tesla"