Lists
Sort Data Model
6min
The Sort Data Model action sorts a data model list based on multiple criteria.
- list to be sorted (list<object>): This is both input and output. It will return the updated list in the same variable.
- Sort JSON Configuration: This should be a "Monaco editor", allowing JSON.
- list to be sorted (list<object>): This is both input and output. It will return the updated list in the same variable.
The Sort JSON Configuration should have the following structure:
The list will be sorted based on the cumulative rules described above.
- This represents a field within the data structure that represents a unique value throughout the entire data set (e.g. the row identifier)
- The Sort defines the sorting criteria list where you can sort by multiple fields.
- Field: This specifies the field in the data model to sort by. For example, "path.Field1" refers to a field named "Field1" within an object located at the "path" in the data model.
- OrderType: This determines the sorting order for the specified field. It can have two values:
- Asc: Sorts the field in ascending order (from lowest to highest).
- Desc: Sorts the field in descending order (from highest to lowest).
Updated 14 Apr 2024
Did this page help you?