Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi,
I have a column of revenue over a few different years. I currently have a running total measure for the revenue over time but would like to apply a multplication to the column (to reflect currency exchange rate) before computing the running total. Is it possible to do so with a measure? I tried ammending my current running total code but was unsuccessful.
Data
Year | Revenue | Country |
2020 | $100 | A |
2020 | $120 | B |
2021 | $130 | B |
2022 | $100 | B |
Measure which is the Current Revenue ($) running total in Year returns a measure that when plotted gives 2020 - $220, 2021 - $350, 2022 - $450
I would l like it multiply the revenue by the correct exchange rate based on country and return the running total.
I.e. Exchange rate for country A = 0.5, Exchange rate for country B = 0.6.
Return 2020 = 0.6 x 100 + 0.8 x 120 = $156, 2021 = 156 +0.8 x 130 = $260, 2022 = 260 + 0.8 x 100 = $340
Thanks for any help you can provide!
Current running total code:
Solved! Go to Solution.
Hello @twixy,
Can you please try this approach:
Revenue_Running_Total_Converted =
VAR ExchangeRate =
SWITCH(
SELECTEDVALUE('Tracker'[Country]),
"A", 0.5,
"B", 0.6,
1
)
RETURN
CALCULATE(
SUMX(
'Tracker',
'Tracker'[Revenue] * ExchangeRate
),
FILTER(
ALLSELECTED('Tracker'[Year]),
ISONORAFTER('Tracker'[Year], MAX('Tracker'[Year]), DESC)
)
)
Hello @twixy,
Can you please try this approach:
Revenue_Running_Total_Converted =
VAR ExchangeRate =
SWITCH(
SELECTEDVALUE('Tracker'[Country]),
"A", 0.5,
"B", 0.6,
1
)
RETURN
CALCULATE(
SUMX(
'Tracker',
'Tracker'[Revenue] * ExchangeRate
),
FILTER(
ALLSELECTED('Tracker'[Year]),
ISONORAFTER('Tracker'[Year], MAX('Tracker'[Year]), DESC)
)
)
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
28 | |
12 | |
10 | |
10 | |
6 |