Forum Discussion

thhmez7's avatar
thhmez7
Icon for Helper III rankHelper III
4 years ago
Solved

Concatenate distinct text value

Hi,

I'd like to concatenate the column Brand. Here I created a column:

For Product G there are two data rows with Brand = n. If this is the case, the brand "n" should be displayed only once. It should be treated as a distinct value. So the result should be "n + U" for product G.

 

Thank you for help.

 

  • Hi, thhmez7 ;

    Try this dax about column.

    Concate = 
    CONCATENATEX (
        SUMMARIZE (
            FILTER ( ALL ( 'Table' ), [Product] = EARLIER ( 'Table'[Product] ) ),
            [Brand]
        ),
        [Brand],
        "+",
        'Table'[Brand], ASC
    )
    

    The final show:


    Best Regards,
    Community Support Team _ Yalan Wu
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

2 Replies

  • v-yalanwu-msft's avatar
    v-yalanwu-msft
    Icon for Community Support rankCommunity Support

    Hi, thhmez7 ;

    Try this dax about column.

    Concate = 
    CONCATENATEX (
        SUMMARIZE (
            FILTER ( ALL ( 'Table' ), [Product] = EARLIER ( 'Table'[Product] ) ),
            [Brand]
        ),
        [Brand],
        "+",
        'Table'[Brand], ASC
    )
    

    The final show:


    Best Regards,
    Community Support Team _ Yalan Wu
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • thhmez7's avatar
      thhmez7
      Icon for Helper III rankHelper III

      thanks, looks good. my use case changed a bit, but it surely helps 🙂