Forum Discussion

Jilanibasha's avatar
Jilanibasha
Frequent Visitor
5 years ago
Solved

Concatinate multiple columns in single column

Hi Gurus,

 

what is the dax formula to display data in below format. Can some one please suggest onthis.

 

 

Thanks,

Jilani

4 Replies

  • Greg_Deckler's avatar
    Greg_Deckler
    Icon for Community Champion rankCommunity Champion

    Jilanibasha You want UNICHAR(10). So like:

    [Column 1] & UNICHAR(10) & [Column 2] & UNICHAR(10) & ...
    • Jilanibasha's avatar
      Jilanibasha
      Frequent Visitor

      Hi Greg,

       

      first column is text column and second one is calculated measure, i could not able ot add using & operator creating new measure. In measure text is not accepting.

      let assume i have Region dimention field, Amount is calculated measure and percentage is calculated measure

      Region Amout percentage

      West    5000      75

       

      need to display West - 5000 - 75

       

      Please help according to this

       

      • Greg_Deckler's avatar
        Greg_Deckler
        Icon for Community Champion rankCommunity Champion

        Jilanibasha Measure = MAX('Table'[Region]) & " - " & [Amount] & " - " & [percentage]

         

        How did we go from columns to measures and from new lines to dashes?

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

    Hi, Jilanibasha 

    According to your description, I can roughly understand your requirement, I think you can use the COMBINEVALUES() to perfectly achieve this:

    Measure = COMBINEVALUES(" - ",MAX('Table'[Region]),[Amount1],[percentage1])

     

    Then you can create a card visual to place this measure, and you can get what you want.

     

    You can download my test pbix file below

    More info about the COMBINEVALUES() function in DAX

    Thank you very much!

     

    Best Regards,

    Community Support Team _Robert Qin

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.