DAX REMOVEFILTERS function
Clears filters from a table or columns, inside CALCULATE.
REMOVEFILTERS does one thing: remove filters. It only works as a modifier inside CALCULATE, which makes the intent of a measure obvious to the next person reading it.
Syntax
REMOVEFILTERS([<table> | <column>[, <column>[, …]]])| Argument | Required | Description |
|---|---|---|
| table or column | Optional | The table or columns to clear filters from. With no argument, all filters are removed. |
Returns: Nothing: it changes the filters of the CALCULATE around it.
Examples
Calculated on the free practice data (table financials), with [Total Sales] = SUM(financials[Sales]) and [Total Profit] = SUM(financials[Profit]).
1. Segment share of sales
Segment Share = DIVIDE([Total Sales], CALCULATE([Total Sales], REMOVEFILTERS(financials[Segment])))| Segment | Segment Share |
|---|---|
| Channel Partners | 1.52% |
| Enterprise | 16.52% |
| Government | 44.22% |
| Midmarket | 2.01% |
| Small Business | 35.74% |
| Total | 100.00% |
Government brings in about 44% of all sales.
Good to know
- Remove filters from the column you group by, not from the whole table, or other filters (like a year slicer) disappear too.
Related functions
Official reference: REMOVEFILTERS function on Microsoft Learn