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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
AbsoluteNovice
New Member

Comparing Dates in Multiple Tables

Hi,

I'm pretty new to Power BI and am completely stumped on this one. I have data in three different tables and I need to find the most recent Meter Reading Date (Table 2) or Overhaul date (Table 3), which ever is greater, for each Asset (Table 1). 

 

Each asset has a unique identified (serial number) but can have multiple Meter Readings and Overhaul dates. 

 

Each table has a lot of other columns I haven't included for simplicity but these the key ones.

 

Table 1 - Assets: 

Serial Number               Asset Status            Asset Location
1234Operational Storeroom 1
1235Operational Storeroom 2
1236Operational Storeroom 3
1237Operational Storeroom 3

 

Table 2 - Meter Readings

Serial Number           Date of Last Reading                     
12341/01/2024
12351/02/2024
12361/03/2024
12371/04/2024
12341/01/2022
12351/02/2022
12361/03/2022
12371/04/2022
12341/01/2020
12351/02/2020
12361/03/2020
12371/04/2020

 

Table 3 - Overhauls:

Serial NumberDate of Last Reading
12341/04/2024
12351/03/2024
12361/02/2024
12371/01/2024
12341/04/2020
12351/03/2020
12361/02/2020
12371/01/2020

 

Thanks!

1 ACCEPTED SOLUTION
ryan_mayu
Super User
Super User

@AbsoluteNovice 

pls see if this is what you want .

 

create relationships between tables and create a measure

Measure = max(max('Overhauls'[Date of Last Reading]),max('Meter Readings'[Date of Last Reading                     ]))
11.PNG
pls see the attachment below




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Your solutions is so great @ryan_mayu 

Hi, @AbsoluteNovice 

Have you solved the current problem? If yes, you can share your solution here or mark the help that is useful to you as a solution so that other members of the community can quickly find the answer when they encounter similar problems. Thank you again.

 

 

Best Regards

Jianpeng Li

ryan_mayu
Super User
Super User

@AbsoluteNovice 

pls see if this is what you want .

 

create relationships between tables and create a measure

Measure = max(max('Overhauls'[Date of Last Reading]),max('Meter Readings'[Date of Last Reading                     ]))
11.PNG
pls see the attachment below




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




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.