Share this page

# Sort results (order_by)

This section provides information about sorting the entities returned by the ALM Octane REST API during a GET operation on collections.

In this topic:

## Syntax

The order_by parameter has the following syntax:

`order_by=[<direction>]<field name>[[,[<direction>]<field name>]]`

Example: `/defects?order_by=severity,-creation_time`

Back to top

## Guidelines

- Field names are separated by commas (,).

- Sorting is case-insensitive. This means that the values A B C D E a b c d e are sorted like this: A a B b C c D d E e .

- Results can be sorted by any fields of the entity.

- By default, most collections are ordered by name. For best performance, it's recommended to sort by ID.

Example: Get the defects collection, ordered by ID:

`GET .../api/shared_spaces/<space_id>/workspaces/<workspace_id>/defects?order_by=id`

Back to top

See also:

- Querying a collection
- Select fields (fields)
- Query

https://admhelp.microfocus.com ALM Octane 8942
Tips to improve your search results... ALM Octane Help Center ALM Octane Help 23.4-24.3 All View Local Help Center View Online Help Center Version: