ORDERBY

Updated on

ORDERBY is a DAX function that specifies expressions and order directions to determine the sort order within each partition, used within Window functions.

Syntax

ORDERBY(
   [ OrderBy_Expression, ... ],
   [ OrderBy_Direction, ... ]
)
Argument Properties Description
OrderBy_Expression Optional, Repeatable An expression used to determine the sort order.
OrderBy_Direction Optional, Repeatable The order direction of the corresponding OrderBy_Expression. 0/FALSE/DESC – descending; 1/TRUE/ASC – ascending.

Return Values

This function does not return a value.

Remarks

This function can only be used within a window function expression.

Example

See OFFSET.

Contribute » | Contributors: Rick de Groot
Microsoft documentation: https://learn.microsoft.com/en-us/dax/orderby-function-dax

2023-2024 © BI Gorilla. All rights are reserved. Information from Microsoft docs is property of Microsoft Corp. | Privacy Policy