Sort columns in a query
Use the following procedure to sort columns in a query.
-
Navigate to Work queue queries/System
queries.
/
The list of queries appears.
- Create a new query or open the query in which to sort the columns.
-
Click the
Sorting tab.
The Sorting tab is only displayed if the Work queue/Workload/Jobs setting under Enable custom sorting is selected in the System > System settings > System > General.
-
To specify the sort order, on the list of sort orders, select a column and specify the direction as
Ascending or
Descending.
- Job query
-
Sort order 1 (Default: Expected duration, Ascending)
-
Sort order 2 (Default: None, Descending)
Sort order 3 is only available when you specify a column for Sort order 2.
-
Sort order 3 (Default: Disabled)
-
-
Work queue query
-
Sort order 1 (Default: Due date, Ascending)
-
Sort order 2 (Default: Priority, Ascending)
-
Sort order 3 (Default: Pending time, Ascending)
When a Work queue control is added to a new form, by default the None option is displayed on the sort order list. For upgraded and imported forms, the None option is available, but the selected column remains as is. The None option is used for the client-side sorting and is applied to the result set returned even when the custom server-side sorting is enabled. Therefore, the results are sorted on the server and returned, and then the client-side sorting is applied. We recommend that you set the client-side sorting to None when using the server-side sorting.
-
-
System query
-
Sort order 1 (Default: Due date, Ascending)
The default sort order 1 is Completed date and Ascending, if "Completed work" is selected.
-
Sort order 2 (Default: Priority, Ascending)
The default sort order 2 is Pending time and Ascending, if "Completed work" is selected.
-
Sort order 3 (Default: Pending time, Ascending)
The default sort order 3 is None and Descending, if "Completed work" is selected.
-
- Job query
-
Click
Save.
For the Job queue query, the sorted results are displayed in the Job list control at runtime.
For the Work queue query, at runtime, the sorted results are displayed in the Work queue control in the order specified in the query. For example, if you select Pending Time as the display column, the time the activity became pending is displayed in the results.
For the System query, at runtime, the sorted results are displayed in the Workload control. For example, if you select the Pending time as the display column, the time the activity became pending is displayed in the results.