The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello All, I need some help with some results that I am getting on one of my dashboards.
What I need is to get the ratio between the two numbers, however, when I do the calculations the results are not correct, for instance:
Earn hours:
Paid hours:
Ratio calculated by Power BI using DIVIDE formula:
Nov 15: 13.15 / 10.28 = 8.16%
Nov 16: 10.68 / 10.57 = 6.63%
Nov 17: 3.32 / 8.55 = 2.06%
Nov21: 2.95 / 10.25 = 1.83%
Ratio calculated by Power BI using that I currently have:
Nov 15: 13.15 / 10.28 = 179.47%
Nov 16: 10.68 / 10.57 = 145.82%
Nov 17: 3.32 / 8.55 = 45.32%
Nov21: 2.95 / 10.25 = 40.29%
The result of this formula is a little bit closer but it is still off.
The results that I am expecting are:
Nov 15: 13.15 / 10.28 = 127.9%
Nov 16: 10.68 / 10.57 = 101%
Nov 17: 3.32 / 8.55 = 38.8%
Nov21: 2.95 / 10.25 = 28.78%
The summaries in the tables "Earn hours" and "Paid hours" are correct, however, as you can see the calculations are incorrect.
Please let me know if this information is enough, the model comes from a huge database so I complicated to share a usefull model.
Thanks in advance for your help.
Solved! Go to Solution.
Hi @ Johel_D
Based on your question, I have created the following two tables
Then you need to create a relationship for the two tables in the Model View
Then you can use your formula to get the results you want
Measure =
DIVIDE(
SUM('Earn hours'[Earn Hours]),
SUM('Paid hours'[Hours])
)
Best Regards,
Jayleny
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @ Johel_D
Based on your question, I have created the following two tables
Then you need to create a relationship for the two tables in the Model View
Then you can use your formula to get the results you want
Measure =
DIVIDE(
SUM('Earn hours'[Earn Hours]),
SUM('Paid hours'[Hours])
)
Best Regards,
Jayleny
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
27 | |
12 | |
8 | |
8 | |
5 |
User | Count |
---|---|
31 | |
15 | |
12 | |
11 | |
7 |