Computed Field Methods
Concatenate
Concatenates the output of two or more fields:
- If the fields’ outputs are all strings, the output is a single string.
- If any field output is an array, the output is an array if the array lengths match. The output is a string if the array lengths are unequal (using the first element of each array).
- If a string output is present among arrays, Sensible repeats its value for every element of the output.
Parameters
The following parameters are in the computed field’s global Method parameter:
key | value | description |
---|---|---|
id (required) | concat | |
source_ids (required) | array of field IDs in the current config | a list of field ids to concatenate in the config |
delimiter | string. default: ” “ | The delimiter with which to join the output of the source fields |
Examples
The following example shows using the Concat method to concatenate two address fields into one.
Config
JSON
Example document
The following image shows the example document used with this example config:
Example document | Download link |
---|
Output
[