Forum Discussion
Wrong Total
Hi Everyone,
I am creating a measure, Measure = divide(sum(amount),count(task)), this is giving me incorrect total.
This is a sample data, in which the line items of Measure = divide(sum(amount),count(task)) is correct, but the total in bottom is incorrect, could you please help.
Abhishek
12 Replies
- TomMartensSuper User
Hey,
it's not totally clear, what's wrong (at least not for me)
Can you please explain what the number 11688 (Task) for Solution "A" represents
- a task id
- the no of tasks meaning the number of rows filter implicitly by Solution "A"
What is your expected result? And what does the Measure = Count('tablename'[Task] return for each row and also the total value.
Regards,
Tom- AbhishekPandeyHelper I
Hi There,
What i am trying to achieve here is :
Divide sum of amount with count of task, now what i am getting in Power BI is
Now the expected result is
Basically Power BI should return the sum of the measure i.e 17500, but it is returning 2500 which is 17500/7, how can i get the sum of the measure as total in Power BI.
Thanks
- AbhishekPandeyHelper I
Hi,
Just want to update here, i have used
SUMX(VALUES(table1[Solution]), CALCULATE(SUM(Table2[Amount]))/CALCULATE(COUNT(task)))
and the total seems working fine for solution only, but when i drag some other dimension attribute then, it divide the values correctly, but returns an incorrect total.
Thanks,