Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Gumberculeez
Helper II
Helper II

SUM based on month

Hey Guys;

 

I'm having issues wrapping my head around this sum issue I'm having.  playing with SQL data and when I leave my Total as "Don't Summarize", it pulls through the monthly revenue for that department...

 

However, as soon as I SUM the total, it ignores the date range and gives me a SUM total of all records with that department ID.  

 

Any ideas guys?

 

 

   Power BI Works.png

5 REPLIES 5
MFelix
Super User
Super User

Hi @Gumberculeez ,

 

Calculations in PowerBI (DAX) are made based on context, so looking at your print screen the information you have on your data is AccountName and Total so for calculation of the sum of Total the only context is the AccountName so what happens is that the final result is the total for all the values of AccountName.

 

If you want to have the calculation per month you need to also add the date to the visual in order to get the context of the month.

 

When you select the Don't summarize option what you are asking is to return the full data for Total column that's why you see all the information per month, again, this is the context that you are giving to your data in this case to not summarize your information with an aggregator.

 

If you need any further assistance or explanation please tell me.

 

Regards,

MFelix

 


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Thanks for that :)... helping a bit.  My underlying issue remains however.  

 

When pick a specific account number it filters only those transactions, however, the total at the bottom remains the overall total for the month.

 

I'd like only the filtered number total to appear.

Hi @Gumberculeez
Can you share some sample data and expected result?

Regards,
MFelix

Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



I'd prefer to not... It's our business system live data.  I can share some screenshots however :).   This Account total is a single invoice, and really... the total and the sum'd total (in this case should match).  they do not however.

 

Power BI issue.png

Hi @Gumberculeez,
I understan that the information is sensitive, can you make a mockup data no need to have actual values but I must have the structure of the data and the way columns are filled.

As you may understand a screenshot with only one line is not suficient to help you.

😁😁😁

Regards,
MFelix

Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.