You can use array functionsWithin a bundle, data items of the same type are sometimes in an array. You can find an array by looking at the details of a bundle. Depending on the details of your scenario, you can map other modules to a specific item in an array or use iterators and aggregators to manipulate your data into other formats. When mapping,... to transform array data. ArrayWithin a bundle, data items of the same type are sometimes in an array. You can find an array by looking at the details of a bundle. Depending on the details of your scenario, you can map other modules to a specific item in an array or use iterators and aggregators to manipulate your data into other formats. When mapping,... functionsFunctions you can use in Boost.space Integrator - create, update, delete, get, search. can, for example, search and sort the items in an array, perform mathematical operationsAn operation is a task performed by module., convert arrays to collections, reorder the items in an array, and more. Below is a list of supported array functions and a description what of each functionFunctions you can use in Boost.space Integrator - create, update, delete, get, search. does.
Adds values specified in parameters to an array and returns that array.
Removes duplicates inside an array. Use the key argument to access properties inside complex objects. To access nested properties, use dot notation. The first item in an array is index 1.
distinct(
Contacts[]
;
name )
= Removes duplicates inside an array of contacts by comparing the name property.
Creates a new array with all sub-array elements concatenated into it recursively up to the specified depth.
More details about flatten function can be found at the Array.prototype.flat documentation.
Concatenates all the items of an array into a string, using a specified separator between each item.
Returns a primitive array containing values of a complex array. Allows filtering values. Use raw variable names for keys.
map(
Emails[]
;
email )
= Returns a primitive array with emails.
map(
Emails[]
;
email ;
label ;
work,home )
= Returns a primitive array with emails that have a label equal to work or home.
See also Mapping: Accessing array’s elements by a key and our Extract an item and/or its value from an array of collections video tutorial.
Removes values specified in the parameters of an array. Effective only in case of primitive arrays of text or numbers.
Returns a new array containing only selected items. The first item in the array has an index of 0.
Sorts values of an array. The valid values of the order
parameter are:
asc
(default) – ascending order: 1, 2, 3, … for type Number. A, B, C, a, b, c, … for type Text.desc
– descending order: …, 3, 2, 1 for type Number. …, c, b, a, C, B, A for type Text.asc ci
– case insensitive ascending order: A, a, B, b, C, c, … for type Text.desc ci
– case insensitive descending order: …, C, c, B, b, A, a for type Text.
Use the key
parameter to access properties inside complex objects. Use raw variable names for keys. To access nested properties, use dot notation. The first item in an array is index 1.
Example 2. sort(
Contacts[]
;
name )
Sorts an array of contacts by the name property in default ascending order.
Example 3. sort(
Contacts[]
;
desc ;
name )
Sorts an array of contacts by the name property in descending order.
Example 4. sort(
Contacts[]
;
asc ci ;
name )
Sorts an array of contacts by the name property in case insensitive ascending order.
Example 5. sort(
Emails[]
;
sender.name )
Sorts an array of emails by the sender.name property.