Forum Discussion
Calculated column IF always returns FALSE
I have the following calculated column, and for some reason it will always return to the FALSE expression (i.e. it always uses the RateToDollar):
TransactionAmountConverted = CALCULATE(VALUES(Transactions[TransactionAmount]) * (IF([CurrencyFilter] = "EUR", VALUES('Currency'[RateToEuro]), VALUES('Currency'[RateToDollar]))))The CurrencyFilter is a calculated measure that gets a report level filter value:
CurrencyFilter = IF(LASTNONBLANK('CurrencyFormat'[Name], 1) = "USD", "USD", "EUR")I have tested the CurrencyFilter value and it is a 'text' value that indeed is set to "USD" or "EUR" depending on the report filter. Now I really do not understand why the IF statement in the calculated column always goes to the FALSE part...
Anyone has any ideas? Any help is much appreciated!
5 Replies
- Greg_Deckler
Community Champion
Hmm, that's probably a difficult one to troubleshoot, it is most like some kind of context issue.
- Fraukje
Advocate II
Any ideas how to troubleshoot it?
- Greg_Deckler
Community Champion
Would need some sample/example data or for you to share a link to your PBIX file. Context issues are tricky.