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
Anonymous
Not applicable

Divide sum of values by single group value

Hello,

 

I have a table where one of the columns qty is shown as the full Phase code qty and not the single line item.

 

For example in the table below the period qty is 45 for the full phase code 12345 not 90. The hours are shown on the individual row/category level however. 

 

What I need is to find a way to divide the sum of the hours (2300) by the group period quantity (45).

 

Phase CodeCategoryPeriod QtyPeriod HoursExpected Hours/QTY
123450145180051.1
12345024550051.1



I'm a bit stuck - does anyone have advice for a good way to do this?

 

Thanks in advance!

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , Try a measure like

 

divide(sum(Table[Period Hours]), sumx(summarize(Table, Table[Phase Code], Table[Period Qty]),[Period Qty]))

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Thank you @amitchandak I'll try that out!

Anonymous
Not applicable

HI @Anonymous,

DId amitchandak 's suggestion help for your scenario? If that is the case, you can consider Kudo or accept his suggestions to help others who faced similar requirements to find this more quickly.

If not help, please share some more detailed information to help us clarify your requirements.

How to Get Your Question Answered Quickly

Regards,

Xiaoxin Sheng

amitchandak
Super User
Super User

@Anonymous , Try a measure like

 

divide(sum(Table[Period Hours]), sumx(summarize(Table, Table[Phase Code], Table[Period Qty]),[Period Qty]))

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

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!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 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.