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.
Hello!
I have two tables:
Article id | Currency |
1 | USD |
2 | EUR |
3 | EUR |
4 | EUR |
Transaction | Article id | Quantity | Price USD |
1 | 1 | 5 | 100 |
2 | 1 | 5 | 100 |
3 | 3 | 5 | 100 |
4 | 3 | 5 | 100 |
I need to create a measure to multiply the quantity and the price USD, but when an article is registered as currency = EUR, I need to multiply the quantity for the PriceUSD and for a constant that would be the exchange rate.
I was able to do this in a table buy I need to put it also in a card.
Can anyone help me with this?
Solved! Go to Solution.
Hi, @AndresOHV
Please try formula like
Measure =
SWITCH (
MAX ( Table1[Currency] ),
"EUR",
MAX ( Table2[Price USD] ) * MAX ( Table2[Quantity] ) * [rate],
"USD", MAX ( Table2[Price USD] ) * MAX ( Table2[Quantity] )
)
If it doesn't work for you, please share more details.
Best Regards,
Community Support Team _ Eason
Hi, @AndresOHV
Please try formula like
Measure =
SWITCH (
MAX ( Table1[Currency] ),
"EUR",
MAX ( Table2[Price USD] ) * MAX ( Table2[Quantity] ) * [rate],
"USD", MAX ( Table2[Price USD] ) * MAX ( Table2[Quantity] )
)
If it doesn't work for you, please share more details.
Best Regards,
Community Support Team _ Eason
Thank you! This worked!
@AndresOHV , A new measure like , Assume Table 1 and Table 2 has 1 _m relationship
Sumx(Table2, Var _curr = related( Table[Currency])
return
if(_curr= "EUR", .98 , 1) *[Price USD] *[Qty])
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
22 | |
7 | |
6 | |
6 | |
6 |
User | Count |
---|---|
27 | |
10 | |
10 | |
9 | |
6 |