DETAILROWS DAX Function (Table manipulation)  Context Transition

Returns the table data corresponding to the DetailRows expression defined on the specified Measure. If a DetailRows expression is not defined then the entire table to which the Measure belongs is returned.

Syntax

DETAILROWS ( <Measure> )
Parameter Attributes Description
Measure

A Measure reference whose DetailRows expression is to be evaluated.

Return values

Table An entire table or a table with one or more columns.

Remarks

IMPORTANT : DETAILROWS should perform a context transition, but in SSAS 2017 it does not do that. The behavior by design is to perform a context transition, and this should be fixed in upcoming hotfix or service packs. As a workaround, if called in a row context, it should be wrapped in a CALCULATETABLE statement. Do not use in a row context if the intended behavior should not execute the context transition – assign the result of DETAILROWS in a variable before the iterator in that case.

Related articles

Learn more about DETAILROWS in the following articles:

Last update: Dec 1, 2018   » Contribute   » Show contributors

Contributors: Alberto Ferrari, Marco Russo

DAX Conventions
Context Transition

This function performs a Context Transition if called in a Row Context. Click to read more.

Row Context

This expression is executed in a Row Context. Click to read more.

Iterator

Not recommended

The use of this function is not recommended. See Remarks and Related functions for alternatives.

Not recommended

The use of this parameter is not recommended.

Deprecated

This function is deprecated. Jump to the Alternatives section to see the function to use.

Deprecated

This parameter is deprecated and its use is not recommended.

Contribute

Want to improve the content of DETAILROWS? Did you find any issue? Please, report it us!
All submissions will be evaluated for possible updates of the content.