Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Divide specific values in matrix visual with total value

Hello Community,

I have a matrix. I want to calculate weigth for all the months by dividing it with total value.

 

The dax i am using is  

bgtw = DIVIDE(CALCULATE(SUM(LE[BU AM]),ALLSELECTED()),[Total_BU_AM_Measure]) but the values are not coming correctly.
 
For Eg Jan must return me -1259/13221.61 = -0.09 
 
Any help would be much appreciated. Thanks

  • Anonymous's avatar
    Anonymous
    6 years ago

    The above mentioned issue was resolved. The dax used was allexcept and in the dax i mentioned all the column names which i used in the slicers. Hope this helps anyone else. Cheers!!!!!!

5 Replies

  • Hi Anonymous ,

     

    Can you try modifying your DAX to the following:

    bgtw = DIVIDE(

                             CALCULATE( SUM(LE[BU AM]) ), [Total_BU_AM_Measure]

                            ) 

     

    If this helps and resolves the issue, appreciate a Kudos and mark it as a Solution! 🙂

     

    Thanks,

    Pragati

     

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hi Pragati,

       

      this gives me value 1 in all the columns

       

      • v-diye-msft's avatar
        v-diye-msft
        Community Support

        Hi Anonymous 

         

        you might consider creating pbix file that will contain some sample data (remove the confidential info), upload the pbix to onedrive for business and share the link to the file. Please do not forget to describe the expected results based on this sample data.

         

         

  • Anonymous's avatar
    Anonymous
    Not applicable

    The above mentioned issue was resolved. The dax used was allexcept and in the dax i mentioned all the column names which i used in the slicers. Hope this helps anyone else. Cheers!!!!!!