Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago
Solved

Group list into one cell

Hello,

 

I am trying to change the table below :

 

To look like this:

MaterialWork Ctr
9266802471TBD24 TBE22 TBE24

 

Basically have all "Work Ctr" for the material 9266802471 listed into one cell with one space between each. How can I do this ?

 

Regards

  • Anonymous's avatar
    Anonymous
    2 years ago

    Hi Anonymous ,

    You can create a calculated column as below to get it:

    Column = 
    CONCATENATEX (
        FILTER ( 'Table', 'Table'[Material] = EARLIER ( 'Table'[Material] ) ),
        'Table'[Work Ctr],
        " ",
        'Table'[Work Ctr], ASC
    )

    Best Regards

2 Replies

  • read about CONCATENATEX  in DAX, or Text.Combine in Power Query

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous ,

    You can create a calculated column as below to get it:

    Column = 
    CONCATENATEX (
        FILTER ( 'Table', 'Table'[Material] = EARLIER ( 'Table'[Material] ) ),
        'Table'[Work Ctr],
        " ",
        'Table'[Work Ctr], ASC
    )

    Best Regards