Forum Discussion
Context issue when adding measure to a table
- Anonymous4 years ago
Hi Jorritster ,
I updated the sample pbix file provided by tamerj1 (see attachment), please check if that is what you want...
1. Change the cross filter direction as Both
2. Update the formula of measure [Threshold_Passed] as below
Threshold_Passed =VAR YTDTaxable =[YTD_TaxableBasis]VAR Threshold =CALCULATE (SUM ( 'Thresholds'[Threshold] ),FILTER('CDM','CDM'[Direction]=SELECTEDVALUE('Direction'[Direction])) // CROSSFILTER ( CDM[Direction], Direction[Direction], BOTH ))VAR Result =IF (YTDTaxable > Threshold,"TRUE",IF (NOT ISBLANK ( Threshold ),"FALSE"))RETURNResultBest Regards
Hi Jorritster
Here is the sample file with the solution https://we.tl/t-Uz6k0eE0dC
- Jorritster4 years agoFrequent Visitor
Hi tamerj1 ,
That is exactly what I wanted. I will accept it as a solution. However, I have one additional question. As we now change the two-directional filter between contract and country to one-directional, we lose the filter context.
In my own model when I select a particular entity, I still get all the EU-countries to choose from in the country filter. Although, I preferably only see the countries that are contracted for that entity.
Is that still possible or should I accept this little drawback?
- Anonymous4 years agoNot applicable
Hi Jorritster ,
Please try to set the option Cross filter join as Both just like in below screenshot, later check if the visual can display your expected result...
Best Regards
- Jorritster4 years agoFrequent Visitor
Hi Anonymous,
Thanks for your help. I did try this but it creates ambiguity for the Threshold_Passed measure tamerj1 specified above because of the cross filter:
Is there a solution for this?