DAX Function Guide

DISTINCT (column)
Empty image or helper icon

Sam McKay

CEO & Founder

How does the DISTINCT (column) work?
The DISTINCT (column) function (DAX) returns a one-column table that contains the distinct values from the specified column. In other words, duplicate values are removed and only unique values are returned.
DISTINCT (column) Formula Syntax

DISTINCT(
     <column>
)

How do you use the DISTINCT (column)?

The DISTINCT (Column) Function is mainly used for DAX deduplication based on a column. This means that the duplicate values from a column are eliminated and only unique values are kept.

Related Blog Posts

Loading

Considerations when using the DISTINCT (column)?

The results of DISTINCT are affected by the current filter context. If you use the formula to create a measure, the results would change whenever the table was filtered to show only a particular region or a time period.

Related Video Tutorials

Loading

Formula examples using the DISTINCT (column)

=COUNTROWS(DISTINCT(InternetSales_USD[CustomerKey]))

=COUNTROWS(DISTINCT(Dim[Dim]))

= COUNTROWS (DISTINCT (Sales[Salesperson ID]))

Related Courses

Loading