ALL Function
Description:
The ALL function is used for clearing filters and creating calculations on all the rows in a table. It returns all the rows in a table, or all the values in a column, ignoring any filters that might have been applied.
Return Value:
ALL returns an entire table or a table with one or more columns.
Syntax:
ALL( [<TableNameOrColumnName> | <ColumnName>[, <ColumnName>[,…]]]] )
- Description of the parameters:
PARAMETER |
DESCRIPTION |
---|---|
TableName Or ColumnName |
The table or column that you want to clear filters on |
ColumnName |
Optional column in the same base table. Can be added when the first parameter is a column name |
Example:
An example of using the ALL function is to calculate the total amount of sales that ignore all the filters applied on the measure or report.
Total Sales amount =
SUMX(
ALL(Sales),
Sales[SalesAmount]
)
The formula above will calculate the total sales amount, and the result will be the same can import the file apply as shown in the following table.
Related Video: