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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
andrevdhoeven
Regular Visitor

Using a value from table 2 to makes a calculation

Example.png

 

Asked before now with an example.

In PowerBI I like to make a calculation with numbers from 2 tables.

1. sum the hours of a person from table 1 (John has 30 + 5 = 35 hours)

2. divide this sum with the number in table 2 on the record whichs has John's name, in this exemple 35/5.

Powerbi gives an error that says values from table 2 has to be a sum, max or minimum value (aggregation)

How can I use the value which is found in John's record in table 2?

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@andrevdhoeven ,

Try like

divide(sum(Table1[Hour]), MAx(Table2[Hour]))

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

2 REPLIES 2
amitchandak
Super User
Super User

@andrevdhoeven ,

Try like

divide(sum(Table1[Hour]), MAx(Table2[Hour]))

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

divide(sum(Table1[Hour]), MAx(Table2[Hour]))

Using this formula will use the highest value form table 2? Not the value of John's record I suppose? 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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