Forum Discussion
Measure Column does not Total correct
Hi Jaco1965 ,
This as to do with the context of your measures and the way you have setup the database with the link between the Resources values and the tasks and work details (nothing is incorrect) and the measures need to be readjust to give the right result.
Create the following meaaures:
Already created
Inv_Amnt = sum(Work_Detail[Work_Hrs]) * Sum(R_ClassRate[Rate]) New one Total_Inv_value = SUMX(Work_Detail;[Inv_Amnt])
Then use the last one to have your final result:
As you can see changing the way the calculation is made the context changes and the result is correct when compared with the red highlited value.
Again noting wrong with your setup, I tried to make a summarized table, or a group by to use in your measure but would only create more complexity on the measures.
Regards,
MFelix
Check out this blog post by SQLBI
DAX 101: Summing values for the total
https://rebrand.ly/correcttotal
MFelix wrote:Hi Jaco1965 ,
This as to do with the context of your measures and the way you have setup the database with the link between the Resources values and the tasks and work details (nothing is incorrect) and the measures need to be readjust to give the right result.
Create the following meaaures:
Already created
Inv_Amnt = sum(Work_Detail[Work_Hrs]) * Sum(R_ClassRate[Rate]) New one Total_Inv_value = SUMX(Work_Detail;[Inv_Amnt])Then use the last one to have your final result:
As you can see changing the way the calculation is made the context changes and the result is correct when compared with the red highlited value.
Again noting wrong with your setup, I tried to make a summarized table, or a group by to use in your measure but would only create more complexity on the measures.
Regards,
MFelix
DAX 101: Summing values for the total (@FerrariAlberto) https://www.sqlbi.com/articles/summin...
- MFelix7 years agoSuper User
Hi gustavoleo ,
Your post is interesting however in the post there is a simple relation between dates and sales and is related with the granularity of the information, in the case of Jaco1965 is model is not simple because he uses two dimension tables to get the calculation made and between two of them there is a bidirectionality that changes the ways tables interact.
That's why the easier way is to create a separate measure thar uses the first one as a parameter, giving context in different places for the total row.
Regards,
MFelix
- Jaco19657 years agoFrequent Visitor
Hi MrFelix
I tried that but I get error with the sumx, it odes not give me option to select the measure from list
- Jaco19657 years agoFrequent Visitor
Hi MrFelix
You are the man. Thanks