Forum Discussion

gauravnarchal's avatar
gauravnarchal
Icon for Post Prodigy rankPost Prodigy
4 years ago
Solved

Issue with Percentage Total

Dear All

 

I am using the below measure to get the available limit in percentage. I am getting the desired result but the total percentage is not reflected correctly in the result. It always shows 0%.

 

Measure

 

AvailableLimit = DIVIDE([BalanceRemaining],[CreditLimit],0)

 

 

 

  • Anonymous's avatar
    Anonymous
    4 years ago

    Hi gauravnarchal ,

    You can create a another new measure as below to get the correct total percentage, then put this new measure onto the table visual to replace the measure [Available Limit]. Please find the attachment for the details.

    Measure = SUMX(VALUES('ClientMaster'[ProfileNameGroup]),[AvailableLimit])

    Best Regards

7 Replies

  • AlexanderPrime's avatar
    AlexanderPrime
    Icon for Solution Supplier rankSolution Supplier

    That 0 on the end is the "alternative result if error when dividing by 0" result. Which would return 0%, this indicates there may be a problem with it dividing Balance Remaining and Credit Limit, are they both set as whole/decimal number? What happens if you remove the ,0? 

    • gauravnarchal's avatar
      gauravnarchal
      Icon for Post Prodigy rankPost Prodigy

      AlexanderPrime  - If I remove "0" it does not show any value in the total.

       

      Also, Balance Remaining and Credit Limit both are set as decimal numbers.

       

       

      • AlexanderPrime's avatar
        AlexanderPrime
        Icon for Solution Supplier rankSolution Supplier

        Does doing it like in the below image work? (May need forum admins to approve attached image if not showing, if it doesn't load. try using: 

        AvailableLimit = DIVIDE(SUM('Table'[BalanceRemaining]),(SUM('Table'[CreditLimit])))    Replacing 'Table' with the respective table name.)



        Is this going into a matrix? Or a visual for each indiviual record. Need a bit more context of what you are trying to do with it if the below doesn't work.