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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
VinhDam
New Member

Sum with Grouping

Hi everyone,

 

I have a simple table like below:

 

Sales  Aging

$100   1

$200   2

$300   5

$400   9

$500   15

 

I would like to to perform different sums based on aging, for example, sum of Sales if Aging is between 1 and 2; sum of Sales if Aging is between 2 and 5; or sum of Sales if Aging > 5

 

How would I construct such a report?

 

Many thanks for your help.

1 ACCEPTED SOLUTION
greggyb
Resident Rockstar
Resident Rockstar

Are the groups static, or do they need to be dynamic based on a user selection?

 

If they're static, it's easy. Make a new field (preferably at your data source if you can, else in a query (e.g. in Power Query) before the data is added to the Power Pivot model) with those groups. Then you can just create visualizations against the new field that contains the group.

 

If they must be dynamic based on user selection, you'll have to give us some more detail on what your expected use case is, and the solution will be a bit more complex.

View solution in original post

22 REPLIES 22
greggyb
Resident Rockstar
Resident Rockstar

Are the groups static, or do they need to be dynamic based on a user selection?

 

If they're static, it's easy. Make a new field (preferably at your data source if you can, else in a query (e.g. in Power Query) before the data is added to the Power Pivot model) with those groups. Then you can just create visualizations against the new field that contains the group.

 

If they must be dynamic based on user selection, you'll have to give us some more detail on what your expected use case is, and the solution will be a bit more complex.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors