Forum Discussion

ppgandhi11's avatar
ppgandhi11
Helper V
7 years ago
Solved

DAX formula help comma separated list

Hi, I have a list such as:

 

Provider    Specialties

A                 AB, BC, CD

B                 AB

C                 BC

D                 CD, DE

 

From above, I want to generate a list like:

 

Provider          Specialties

A                       AB

A                       BC

A                       CD

B                        AB

C                        BC

D                        CD

D                         DE

 

How can I generate such list? they are always comma separated coming from the source. Thanks.

2 Replies

  • Vvelarde's avatar
    Vvelarde
    Community Champion

    ppgandhi11

     

    Hi, In Edit Query

     

    Select Your Column Specialties

     

    Transform-Split Columns

     

    Delimiter--> Comma

     

    Advance Options--Split into Rows

     

    Regards

     

    Victor

  • v-danhe-msft's avatar
    v-danhe-msft
    Microsoft Employee

    Hi ppgandhi11,

    Based on my test, you could refer to below steps:

    Sample data:

    Split teh [Special] column by ",":

     

    Unpivot all the column except the [provider] column:

    Remove the extra column, now you can see the result:

    You could also download the pbix file to have a view.

     

    Regards,

    Daniel He