Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi
I have a measure which have calculated the total discount on a customer(cust_disc).
Given this discount I would like to find from the table below(discounttable) what the turnover should have been at least with this discount. For example with a discount of 48,1% the turnover should be at least 300.000
How would you write that measure to find the value 300.000?
Solved! Go to Solution.
@Dennis_Pedersen , Try using below DAX
Minimum Turnover =
VAR Discount = [cust_disc] // Replace [cust_disc] with your actual measure for calculating the total discount on a customer
RETURN
CALCULATE(
SUM(discounttable[Turnover]),
discounttable[Discount] >= Discount,
FILTER(
ALL(discounttable),
discounttable[Discount] >= Discount
)
)
Proud to be a Super User! |
|
@Dennis_Pedersen , Try using below DAX
Minimum Turnover =
VAR Discount = [cust_disc] // Replace [cust_disc] with your actual measure for calculating the total discount on a customer
RETURN
CALCULATE(
SUM(discounttable[Turnover]),
discounttable[Discount] >= Discount,
FILTER(
ALL(discounttable),
discounttable[Discount] >= Discount
)
)
Proud to be a Super User! |
|
Thanks a lot. That helped me in the right direction.
However I had to ammend it a little, with making a discount from and discount to, to make it work correct.
VAR Discount = [Total discount_ %]
RETURN
CALCULATE(
[Amount from],
Discount >=DIM_Segmentering[Discount from],
FILTER(
ALL(DIM_Segmentering),
Discount<DIM_Segmentering[Discount to]
)
)
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 8 | |
| 7 | |
| 6 | |
| 5 | |
| 4 |
| User | Count |
|---|---|
| 25 | |
| 11 | |
| 8 | |
| 8 | |
| 8 |