Forum Discussion
Anonymous
4 years agoNot applicable
DAX: FILTER and CONCATENATE UNIQUE values
I am trying to FILTER/LOOKUPVALUE and CONCATENATE the relevant UNIQUE values but right now, I am unable to get it to work. I can only do it without the values being UNIQUE.
My current DAX formula:
My current DAX formula:
CONCATENATEX (
FILTER (
ALL ( Table2 ),
Table2[Column1] = Table1[Column1]
),
Table2[Column2],
", "
)
The output from here goes like:
Value1, Value2, Value2
My desired output is: (without any of the values being duplicated)
Value1, Value2
The output from here goes like:
Value1, Value2, Value2
My desired output is: (without any of the values being duplicated)
Value1, Value2
Anonymous , Assuming this is a new column, I tried the same on my data, a new column. without all
Column = CONCATENATEX(summarize(FILTER(Sales,Sales[Item ID] = 'Item'[Item Id]), Sales[City Id]),[City Id], ",")
6 Replies
- amitchandak
Super User
Anonymous , try like
CONCATENATEX (
summarize(FILTER (
ALL ( Table2 ),
Table2[Column1] = cvShipments[Column1]
),
Table2[Column2]),
", "
)- AnonymousNot applicable
amitchandak Hi there, thanks for commenting. I tried but the output that I've obtained is "," and ", ,"
Seems like only commas are being concatenated here...- amitchandak
Super User
Anonymous , Assuming this is a new column, I tried the same on my data, a new column. without all
Column = CONCATENATEX(summarize(FILTER(Sales,Sales[Item ID] = 'Item'[Item Id]), Sales[City Id]),[City Id], ",")
- smpa01
Community Champion
Anonymous provide sample data and expected output to accelerate response