Forum Discussion

AtchayaP's avatar
AtchayaP
Helper V
4 years ago
Solved

Powerbi

This is a column in a table.i want to count this by using delimiter.(comma).

 

 

Vijay_A_Verma 

  • Hi AtchayaP,

     

    Under the assumption you have already loaded the column/table to Power Query, you can go to Transform > Split Column > By Delimiter > Comma (Each occurence of the delimiter):

     

     

    Next you can select all column headers, right click and select Unpivot Columns. This will put all the items in rows:

     

     

    Finally, apply these step changes and create a DAX measure in your model to count the number of rows (either COUNTROWS or DISTINCTCOUNT). Hope this helps.

2 Replies

  • BITomS's avatar
    BITomS
    Solution Supplier

    Hi AtchayaP,

     

    Under the assumption you have already loaded the column/table to Power Query, you can go to Transform > Split Column > By Delimiter > Comma (Each occurence of the delimiter):

     

     

    Next you can select all column headers, right click and select Unpivot Columns. This will put all the items in rows:

     

     

    Finally, apply these step changes and create a DAX measure in your model to count the number of rows (either COUNTROWS or DISTINCTCOUNT). Hope this helps.

    • BITomS's avatar
      BITomS
      Solution Supplier

      Even simpler, you can expand 'Advanced Options' within the Split Column by Delimiter screenshot and split them to rows, which would skip out the middle step!