Forum Discussion
Problem with SumX
Dennis_Pedersen , try with these small changes
New measure:=
VAR _weight=
AVERAGEX(values(vDIM_Items[ItemID]),CALCULATE([NetWeight_])
, REMOVEFILTERS(DIM_Time))
return
sumx(values(vDIM_Items[ItemID]),CALCULATE([QTY]*_weight))
- Dennis_Pedersen4 years agoHelper I
Thank you amitchandak
Unfortunately the same result with no calculation on the last style. I really don't get it bacause the sold Qty is calculated correct on that style also, so it should be possible to calculate the weight also??
Also I changed you formula a bit:(before it said too many arguments for averageX function)
VAR _weight=
AVERAGEX(values(vDIM_Items[ItemID]),CALCULATE([NetWeight_]
, REMOVEFILTERS(DIM_Time)))return
sumx(values(vDIM_Items[ItemID]),CALCULATE([QTY]*_weight))
- amitchandak4 years agoSuper User
Dennis_Pedersen ,
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.- Dennis_Pedersen4 years agoHelper I
Hi amitchandak
Thank you - I have sent you a PM