Forum Discussion
mbg032373
5 years agoRegular Visitor
Matrix subtotals incorrect when using Measure
I have tried several different solutions posted here and other places trying to get this to work out, but I seem to just not be getting it. I'm trying to create a balance sheet, which I have mostly ...
mbg032373
5 years agoRegular Visitor
Greg_Deckler I figured out why NET INCOME wasn't getting populated for me, so I think we are getting really close now. Now I just need to figure out how to get NET INCOME actually calculated correctly using SUMX.
Here is the actual measure used to get NET INCOME:
Net Income =
CALCULATE(TOTALMTD(SUM(HuntLedgerTransactions[USD Amount]),HuntDate[DATEKEY]),
HuntLedgerTransactions[Statement Type] = "Income Statement",REMOVEFILTERS(HuntMainAccounts)
)How would I accomplish the same results using SUMX?
Greg_Deckler
5 years agoCommunity Champion
mbg032373 Well, fundamentally, you would use HASONEVALUE and return that measure if true. If false, you would use SUMMARIZE or SUMMARIZECOLUMNS to group your items just like they are in the matrix visual and put this in a table VAR. You would use ADDCOLUMNS to add this measure as a calculated column within that table VAR and then you would SUMX across it.