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.
Good day!
With this data, I am building a simple table, showing the Total at the bottom.
p.s. the Earn% = (Sell - Buy) / Buy
Name | Buy | Sell | Earn % |
John | 74 | 84 | 13.5% |
Kate | 50 | 57 | 14.0% |
Peter | 46 | 73 | 58.7% |
In PowerBI, it gives me a table. the Total Earn% I want it to show 25.9%, which is from (214 - 170) / 170 (instead of a sum of the Earn% column).
How can I do that? Thank you.
Solved! Go to Solution.
Hi @JohnDahis ,
You may try to use a measure. You can find New Measure on the Home Tab.
Click and create a new measure (Earn %) as below:
Earn % =
var buy = SUM('Table'[Buy])
var sell = SUM('Table'[Sell])
return
DIVIDE(sell - buy,buy)
@JohnDahis , Try like
Earn % new = sumx(values(Table[Name]),[Earn %])
In place [Earn %] , you have its calculation
@amitchandakthank you for your reply and adivse.
I folloewed the same, however it doesn't return what's wanted. How can I correct it? Thanks.
Hi @JohnDahis ,
You may try to use a measure. You can find New Measure on the Home Tab.
Click and create a new measure (Earn %) as below:
Earn % =
var buy = SUM('Table'[Buy])
var sell = SUM('Table'[Sell])
return
DIVIDE(sell - buy,buy)
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
114 | |
98 | |
86 | |
70 | |
62 |
User | Count |
---|---|
151 | |
120 | |
103 | |
87 | |
68 |