Sort

This node allows you to sort a list of objects by a given pointer.

Imagine you have an ad object from which you need to sort the data on a specific condition using the pointer. You will also be able to choose whether you want to sort on an ascending way or descending using the direction input.

Take a look at the example below to understand better how you can use it:

Example:

Notion image

Input Fields

field
schema
explanation
items
any
Input the data that needs to be sorted in this socket.
pointer
string
Input the path to the desired value. In our examples, to get sorted by spend, we use /spend as a pointer.
direction
sort_direction
Select the sort direction from the list.

Output Fields

field
schema
explanation
items
any
Output the sorted items.
 
Did this answer your question?
😞
😐
🤩

Last updated on December 13, 2022