DAX Functions

KEEPFILTERS Function

Pinterest LinkedIn Tumblr

DAX KEEPFILTERS Function is categorized under Filter functions. KEEPFILTER is a filter modifier. KEEPFILTERS is necessary when you have arbitrarily shaped filters that you do not want to lose by applying additional filters on individual columns.

DAX-KEEPFILTERS-Function

Purpose of DAX KEEPFILTERS Function

The KEEPFILTERS function modifies how filters are applied while evaluating a CALCULATE or CALCULATETABLE function.

Return value

The DAX KEEPFILTERS function doesnot return any value.

Syntax

= KEEPFILTERS(<expression>)

Arguments

ArgumentsDescriptionRemarks
expression Any DAX expression.Mandatory

Usage notes

To override the standard behavior of CALCULATE and CALCULATETABLE functions, You can use DAX KEEPFILTERS function within the context of those function.

Any existing filters in the current context are compared with the columns in the filter arguments when you use KEEPFILTER and when the arguments intersects, the intersection is used as the context for evaluating the expression.

The net effect over any one column is that both sets of arguments apply −

  • The filter arguments used in CALCULATE function.
  • The filters in the arguments of the KEEPFILTER function.

In other words, while CALCULATE filters replace the current context, KEEPFILTERS adds filters to the current context.

Related Posts

More off this less hello salamander lied porpoise much over tightly circa horse taped so innocuously outside crud mightily…

Write A Comment