Cheat Sheets/Power BI/DISTINCT
DAX function

DISTINCTDAX function reference

Distinct rows of a table.

Syntax

dax
DISTINCT(<table> | <column>)

Examples

dax
DISTINCT(Sales[Region])
A table
dax
COUNTROWS(DISTINCT(Sales[CustomerID]))
Same result as DISTINCTCOUNT(Sales[CustomerID]), written as a table expression

DISTINCT can operate on a multi-column virtual table, not just a single column.

dax
DISTINCT(SELECTCOLUMNS(Sales, "Region", Sales[Region], "Channel", Sales[Channel]))
Distinct Region/Channel combinations

Common mistakes & gotchas

Related DAX functions

From Tables & set operations

Used in these tutorials

← Back to the Power BI (DAX) cheat sheet