Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

One value as a percent of another

Hi! 

 

I have two DAX formulas:

 

Overdue AR = 
 CALCULATE(
 SUM(HFM[0-90]), 
 FILTER(HFM,HFM[Helper]=MAX(HFM[Helper])))
AR Trade = 
 CALCULATE(
 SUM(HFM[11100]), 
 FILTER(HFM,HFM[Period]=MAX(HFM[Period])
 ))

 

Result of the first one is 3, the result of the other one is 25.

 

I want to create a measure that will show me the percentage of Overdue AR as a total of AR Trade. I have below - as simple as possible, but for some reason, it is not working well (showing 11% instead of 6.5%).

 

Overdue % = DIVIDE(HFM[Overdue AR],HFM[AR Trade])

Any idea what is wrong?

1 ACCEPTED SOLUTION
v-yulgu-msft
Employee
Employee

Hi @Anonymous ,

 


Result of the first one is 3, the result of the other one is 25.

 

I want to create a measure that will show me the percentage of Overdue AR as a total of AR Trade. I have below - as simple as possible, but for some reason, it is not working well (showing 11% instead of 6.5%).


How to get the result of 6.5%? It looks like calculating "the percentage of Overdue AR as a total of AR Trade. " returns 3/25=12%. Please illustrate your scenarion with sample data and desired output. How to Get Your Question Answered Quickly

 

Best regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-yulgu-msft
Employee
Employee

Hi @Anonymous ,

 


Result of the first one is 3, the result of the other one is 25.

 

I want to create a measure that will show me the percentage of Overdue AR as a total of AR Trade. I have below - as simple as possible, but for some reason, it is not working well (showing 11% instead of 6.5%).


How to get the result of 6.5%? It looks like calculating "the percentage of Overdue AR as a total of AR Trade. " returns 3/25=12%. Please illustrate your scenarion with sample data and desired output. How to Get Your Question Answered Quickly

 

Best regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Of course, you are right, I feel so embarrassed! I need to go back to Primary school and take some mathematics classes...

 

Regarding your link - this is helpful, I will follow this advice. Thanks a lot! 

Anonymous
Not applicable

Hi,

 

Do you try this formula?

 

Overdue % = DIVIDE(HFM[Overdue AR],CALCULATE(SUM(HFM[AR Trade]); ALL([AR Trade]))

You need to divide for all, correct? 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.