Forum Discussion
Dax to Sum Rows
- 3 years ago
Hi, kunal_mehta1
You can try the following methods.
Column:Number = RIGHT([Project Number],4)Measure = CALCULATE(SUM('Table'[Dollar]),ALLEXCEPT('Table','Table'[Number]))Is this the result you expect?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
hi kunal_mehta1
try like:
Sorry, i would like to elaborate a little.
I have projects with C number and out of those C projects i have few O projects with the same last 4 digits.
I want to sum the dollar values of C and O for that particular project with same last 4 digits.
I want a measure which would sum the C and O rows with same last 4 digits and if it doesn't have the O number just give the value of C number row.
I hope that this makes it clear.
- FreemanZ3 years agoSuper User
could you also provide directly your expected result based on the sampledata?
- kunal_mehta13 years agoHelper I
It would be a measure which will give me sum of dollar vlaue for C7097 and O7097 which would be 30 , next gives me sum of C7088 and O7088 which would be 35, also gives me the value of C7086 even if it doesn't have O number which would be 25.
- v-zhangti3 years agoCommunity Support
Hi, kunal_mehta1
You can try the following methods.
Column:Number = RIGHT([Project Number],4)Measure = CALCULATE(SUM('Table'[Dollar]),ALLEXCEPT('Table','Table'[Number]))Is this the result you expect?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.