Forum Discussion
Aggregated subtotal Measure
- 4 years ago
Once data is in power bi select your order id column:
and at the top set it to "Don't Summarise"
(because it is a number power bi assumes you want to add it up)
Check that the Amount column has summarization set to "Sum".
If you then create matrix visual like this:
Power Bi will do what you require:
Doing it this way Power Bi does the aggragation for you in the background implicitly.
You can however create a measure explictly to do the same thing. RIght click the table and click "Create Measure" and then use the following code:
Order Amount = SUM ( Orders[Amount] )
Once data is in power bi select your order id column:
and at the top set it to "Don't Summarise"
(because it is a number power bi assumes you want to add it up)
Check that the Amount column has summarization set to "Sum".
If you then create matrix visual like this:
Power Bi will do what you require:
Doing it this way Power Bi does the aggragation for you in the background implicitly.
You can however create a measure explictly to do the same thing. RIght click the table and click "Create Measure" and then use the following code:
Order Amount = SUM ( Orders[Amount] )
Thank you!!!