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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
BobKoenen
Helper IV
Helper IV

Multipli values acrros 2 related tables

Hi 

 

I have a large trfact table with the hours per employee per date. I also have an employee table which is linked to this tabel which contains the Hourly rate. I want to Calculate the [sum of hours] * [hourly rate] without having to add an extra column to my large fact table.

Hours table

DateEmployee idHours
1-1-202112
1-1-202113
1-1-202125
2-1-202123

 

My employee table looks like this

Idrate
110
215

 

I Want to multiply the hourly rate times the sum of the hours to get the total amount. 

hope you can help me

1 ACCEPTED SOLUTION
HashamNiaz
Solution Sage
Solution Sage

Hi @BobKoenen !

You need to have following 2 measure;

 

 

Total Hours = SUM(Hours[Hours])

Total Amount = SUMX(RELATEDTABLE(Employee), [Rate] * [Total Hours])

 

Your Employee & Hours table needs to be connected through Active relationship based on EmployeeID column.

 

The first measure calculates [Total Hours], second measure calculates [Total Amount], You can plot this against EmployeeID or any other attribute.

 

Regards,

Hasham

View solution in original post

1 REPLY 1
HashamNiaz
Solution Sage
Solution Sage

Hi @BobKoenen !

You need to have following 2 measure;

 

 

Total Hours = SUM(Hours[Hours])

Total Amount = SUMX(RELATEDTABLE(Employee), [Rate] * [Total Hours])

 

Your Employee & Hours table needs to be connected through Active relationship based on EmployeeID column.

 

The first measure calculates [Total Hours], second measure calculates [Total Amount], You can plot this against EmployeeID or any other attribute.

 

Regards,

Hasham

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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