Forum Discussion
Br1-981
Helper I
2 years agoMeasure to convert currency
Hi, I have a fact table: where sales values are in local currency and I need to convert into GBP using a custom table monthly based: I Would create a measure that for each combinati...
- 2 years ago
Thanks, starting from your approach I developed a new measure:
SPEND_EUR = VAR CurrentMonth = MONTH(Data[Date]) VAR CurrentYear = YEAR(Data[Date]) VAR CurrentCountry = Data[Country_Code] VAR ExchRate = LOOKUPVALUE ( 'ExRate'[Exchange Rates], 'ExRate'[Year], CurrentYear, 'ExRate'[Month], CurrentMonth, 'ExRate'[Country_Code], CurrentCountry ) RETURN WeeklyData[SPEND] * ExchRate
amustafa
Solution Sage
2 years agoSee my solution in this post:
Re: Exchange Rate Conversion with Date Selection (... - Microsoft Fabric Community
- Br1-9812 years ago
Helper I
Thanks, starting from your approach I developed a new measure:
SPEND_EUR = VAR CurrentMonth = MONTH(Data[Date]) VAR CurrentYear = YEAR(Data[Date]) VAR CurrentCountry = Data[Country_Code] VAR ExchRate = LOOKUPVALUE ( 'ExRate'[Exchange Rates], 'ExRate'[Year], CurrentYear, 'ExRate'[Month], CurrentMonth, 'ExRate'[Country_Code], CurrentCountry ) RETURN WeeklyData[SPEND] * ExchRate