Share
Explore

icon picker
List of Operators


Operators
Category
Name
Description
list.firstItem(list)
Returns the first item of the given list or table. If list is empty, returns undefined.
Gives an error if list is not actually a list.
list.getItem(list, index)
Returns the item at the specified index (starting at 0) of the given list or table. If there is no item at the given position, returns undefined.
Example: list.getItem(/googleAds-1234, 0) gives you the first element at the given list.
Gives an error if list is not actually a list.
list.isEmpty(list)
Returns TRUE if the given list or table has at least one element, otherwise FALSE.
Gives an error if list is not actually a list.
list.lastItem(list)
Returns the last item of the given list or table. If list is empty, returns undefined.
Gives an error if list is not actually a list.
list.length(list)
Returns the amount of items in a given list or table.
Gives an error if list is not actually a list.
list.join(list, separator)
Returns a text with all list items separated by the separator.
list.create(item1, item2, ...)
Creates a list from the given items. Can accept zero or more items as parameters, and will output them as a list.
Example:
list.create(5,2,3) will output a list with the values 5, 2 and 3.
list.concat(list1, list2, ...)
Merges together multiple lists. Can accept zero or more lists as parameters, and will output them together as a single list.
Example:
Let’s say /report1 and /report2 output lists of values, then:
list.concat(/report1, /report2)
will output a single list with all the values of the two reports combined.
list.flatten(listOfLists)
Expects a single list as a parameter, where each item in the list is another list. This operator will then merge all lists together and return them as one list of items.
Example:
list.flatten(list.create(list.create(1,2), list.create(3,4)))
will output a single list with the values 1, 2, 3 and 4.
There are no rows in this table

Share
 
Want to print your doc?
This is not the way.
Try clicking the ⋯ next to your doc name or using a keyboard shortcut (
CtrlP
) instead.