Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
I am trying to remove repeated values from a column
that has comma seperated values (Ex, 1,3,4,6,7,9,9,9,9) should return (1,3,4,5,6,9)
I found a match for my issue on stack overflow, which works in the example format, but when I try to apply to my query, I don't understand how to reference a specific column from my source. Would anyone be able to demonstrate to me how to fix this syntax? Thank you.
The example:
let
Source = "Giang.Phan@abc.com, thao.tran@abc.com, Khoa.Vu@abc.com, Vn.Offset@abc.com, Giang.Phan@abc.com, thao.tran@abc.com, Khoa.Vu@abc.com, Vn.Offset@abc.com",
#"Distinct Values" = Text.Combine(List.Distinct(Text.Split(Source, ", ")),", ")
in
#"Distinct Values"
The example above works
My source contains multiple columns, so I tried to reference the column from source like this -
= Text.Combine(List.Distinct(Text.Split(#"PREVIOUS STEP"{"MY COLUMN NAME"}, ",")),",")
let
Source = <A BUNCH OF COLUMNS HERE>,
#"Remove Duplicates" = Text.Combine(List.Distinct(Text.Split(Source{"MY COLUMN NAME"}, ",")),",")
in
#"Remove Duplicates"
Solved! Go to Solution.
@jbbcormed Try adding a custom column like this:
=Text.Combine(List.Distinct(Text.Split([YOUR COLUMN NAME], ", ")),", ")
You can then remove the original column.
@jbbcormed Try adding a custom column like this:
=Text.Combine(List.Distinct(Text.Split([YOUR COLUMN NAME], ", ")),", ")
You can then remove the original column.
Oh my gosh, I don't know why that threw me for a loop, worked like a champ, this is like when I realize I should be doing a calculated column instead of a measure in DAX. "When it no worky, consider you are doing it in the wrong place" haha
Edit: And THANK YOU!
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
15 | |
12 | |
8 | |
8 | |
7 |
User | Count |
---|---|
15 | |
13 | |
9 | |
7 | |
6 |