Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
EugeneB
New Member

Column

I have a few similar and unique values in the same column, and I need only distinctive values, example: US,CA,ATL,ATL,US,FR->US,CA,ATL,FR

2 REPLIES 2
tamerj1
Super User
Super User

Hi @EugeneB 
1.png

Column Distinct = 
VAR String = 'Table'[Column]
VAR Items = SUBSTITUTE ( String, ",", "|" )
VAR Length = COALESCE ( PATHLENGTH ( Items ), 1 )
VAR T1 = GENERATESERIES ( 1, Length, 1 )
VAR T2 = SELECTCOLUMNS ( T1, "@Item", PATHITEM ( Items, [Value] ) )
VAR T3 = DISTINCT ( T2 )
RETURN
    CONCATENATEX ( T3, [@Item], "," )

Thank you it works

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.