You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Sort all valid elements according to a list of attribute values.

Parameter

  • attributes: The list of attribute names to use for sorting
  • ascending: Optional boolean values that flags, if the given list of attributes should be sorted in ascending or descending order. Default value is descending.

Note: Because of the non-decreasing order of time in a data stream sorting is only possible inside a relation with equal start and end timestamp.

Example

PQL
Sort Operator
relation = ELEMENTWINDOW({SLIDE = 5, SIZE=5},  input)

// Sort the stream by the attribute value id.
output = SORT({
                  attributes = ['id']
                 }, relation)

// Sort the stream by the attribute id in ascending order.
output = SORT({
                 attributes = ['id'], 
                 ascending = ['true']
                }, relation)

  • No labels