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.
hi there,
I used the below dax to get the max absolute PAT% of the top 10 customer. When I use this measure for further calculation in a column, this max % changed for different customer. How to fix this max amount for further calculation? (this max % can be changed by slicers only, e.g. when selecting different year it should be updated, currently it works fine with slicer)
Max Abs value new = if(MAXX(SUMMARIZE(T_BO_APO_BGT_FY_ALL,T_BO_APO_BGT_FY_ALL[Customer_G],"rankingnew",[rankingnew],"PAT%",IF([rankingnew]<=10,ABS([Consol PAT%]),BLANK())),[PAT%])<0.08,0.12,MAXX(SUMMARIZE(T_BO_APO_BGT_FY_ALL,T_BO_APO_BGT_FY_ALL[Customer_G],"rankingnew",[rankingnew],"PAT%",IF([rankingnew]<=10,ABS([Consol PAT%]),BLANK())),[PAT%]))
when I put back this measure to the table, the % adjusted for different customer, I expect this is the max amount of the top ten should not be changed in the table
Solved! Go to Solution.
Hi @erihsehc,
You need function CALCULATE to change the context. Try this formula please. The point is calculate.
Max Abs value new = VAR maxValue = CALCULATE ( MAXX ( SUMMARIZE ( T_BO_APO_BGT_FY_ALL, T_BO_APO_BGT_FY_ALL[Customer_G], "rankingnew", [rankingnew], "PAT%", IF ( [rankingnew] <= 10, ABS ( [Consol PAT%] ), BLANK () ) ), [PAT%] ), ALL ( T_BO_APO_BGT_FY_ALL ) ) RETURN IF ( maxValue < 0.08, 0.12, maxValue )
Your date table could be independent.
If you want more help, please share your .pbix file. At least your model structure and the fields of the visual.
Best Regards!
Dale
Hi @erihsehc,
You need function CALCULATE to change the context. Try this formula please. The point is calculate.
Max Abs value new = VAR maxValue = CALCULATE ( MAXX ( SUMMARIZE ( T_BO_APO_BGT_FY_ALL, T_BO_APO_BGT_FY_ALL[Customer_G], "rankingnew", [rankingnew], "PAT%", IF ( [rankingnew] <= 10, ABS ( [Consol PAT%] ), BLANK () ) ), [PAT%] ), ALL ( T_BO_APO_BGT_FY_ALL ) ) RETURN IF ( maxValue < 0.08, 0.12, maxValue )
Your date table could be independent.
If you want more help, please share your .pbix file. At least your model structure and the fields of the visual.
Best Regards!
Dale
get the result, i changed the calculate(,all())to calculate(,allselected()), all fine now thanks @v-jiascu-msft
need help
just like in Excel, we can exactly put formula equal a calculation result, how to do in power bi?
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.