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

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
weisheng
Frequent Visitor

Using aggregated value in a calculation.

Hello all,

 

I am relatively new to Power BI. 

 

In my current project, I have a column of monthly usage. I know that I can pick different aggrated values such as Sum, or Average and it will show at the bottom of the column. I was wondering if I can use that number in a equation for a calculated column. 

 

aggre.PNG

 

Thank you!

5 REPLIES 5
weisheng
Frequent Visitor

Hello all,

 

I am relatively new to Power BI. 

 

In my current project, I have a column of monthly usage. I know that I can pick different aggrated values such as Sum, or Average and it will show at the bottom of the column. I was wondering if I can use that number in a equation for a calculated column. 

 

Thank you!

                                                                                   aggre.PNG

Hi @weisheng,

As you see, the Aggregated Values show at the bottom of the table. But it is not possible to use them directly into some other expression or calculated column

 

Instead you can use that by manually specifying in a DAX statement, for ex. in your case, suppose you want to find the difference between the Total monthly usage and Average monthly usage for each month, you can create and use a measure like the one below

 

Difference = AVERAGE(Table1[Usage]) - SUM(Table1[Usage])

Here AVERAGE(Table1[Usage]) holds the same value as your aggregated column total. i.e. 773.25

 

 

Anonymous
Not applicable

@weisheng yes

 

avg of monthly usage = calculate(avg(table1[monthly usage]), all(table1))

Thanks ! But I am looking to get the value in the red circle and I have a slicer that picked a specific product. So your equation actually returns the average of every monthly usage amonst all product. Im not sure if I am explaining it well.

Anonymous
Not applicable

@weisheng yeah not sure if I can understand from your explanation, you need to provide better raw data, and examples of what is the output you need or provide a power bi other it is impossible to give the right ans in first go.

 

I am going to take another shot in the dark and say but if you want specific to a product then you use

avg of monthly usage by product = calculate(avg(table1[monthly usage]),allexcept(table1,table1[product]) 

 

if you just want the avg of monthly usage and then have it filtered by multiple slicers try this one

 

avg of monthly usage = calculate(avg(table1[monthly usage]),allselected(table1))

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.