Forum Discussion
JimmyHussein
5 years agoNew Member
Count then multiply
I have 2 tables 1:many The sales table which only has the units sold... so each row counts as a sale... the sales table doesn't have a quantity column My product table has the product key wh...
- 5 years ago
Try this
SUMX(productsTable,productsTable[price] * CALCULATE(COUNTROWS(SalesTable)))
amitchandak
Super User
5 years agoJimmyHussein , Try like
sumx(summarize(product, "_1",calcuate(sum(sales[quantity])) , "_2",calcuate(sum(product[price]))), [_1]*[_2])