cancel
Showing results for
Did you mean:
Highlighted
Frequent Visitor

## Create a measure with column of many measures done on different columns from different tables

A measure that calculate

if A.currency = B.currency then(these conditions may be different)

mymeasure = A.measure(sum of price) * B.Exchangerate

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team

## Re: Create a measure with column of many measures done on different columns from different tables

Hi @umangsrivastava ,

Please try to use below formula, I create a summary variable table to stored total sales and correspond exchange rate for calculate:

```Result =
VAR summary =
SUMMARIZE (
T1,
[Currency],
"Total Sales", SUM ( T1[Sales value] ),
"Ex rate", LOOKUPVALUE ( T2[Exchange Rate], T2[Currency], [Currency] )
)
RETURN
SUMX ( summary, [Total Sales] * [Ex rate] )
```

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin Sheng
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

For learning resources/Release notes, please visit: | |
3 REPLIES 3
Community Support Team

## Re: Create a measure with column of many measures done on different columns from different tables

HI @umangsrivastava ,

I think it will be help if you share table structures and sample data for test and coding formula .

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin Sheng
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

For learning resources/Release notes, please visit: | |
Frequent Visitor

## Re: Create a measure with column of many measures done on different columns from different tables

 Table 1 Currency Date Sales value New Measure AED 01-01-2019 100 Sum of sales value currency wise per month AED 02-01-2019 110 AUD 02-01-2019 120

 Table 2 Currency Exchange Rate AED 0.21 AUD 0.71

i need

my measure = New Measure*Exchangerate (currency wise grouped)

i.e for AED

new measure = 110 +100

mymeasure = new measure * Exchangerate(0.21)

Community Support Team

## Re: Create a measure with column of many measures done on different columns from different tables

Hi @umangsrivastava ,

Please try to use below formula, I create a summary variable table to stored total sales and correspond exchange rate for calculate:

```Result =
VAR summary =
SUMMARIZE (
T1,
[Currency],
"Total Sales", SUM ( T1[Sales value] ),
"Ex rate", LOOKUPVALUE ( T2[Exchange Rate], T2[Currency], [Currency] )
)
RETURN
SUMX ( summary, [Total Sales] * [Ex rate] )
```

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin Sheng
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

For learning resources/Release notes, please visit: | |