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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
GeekAlfPro
Helper V
Helper V

Get max hour from max date

Hello,

 

I have a report wherein I want to post the last purchase on a website.

So I have inserted a card and a filter on the most recent one.

It works for the date.

but now I want to display the maximum time of day I picked in the maximum date card

i specify that my hours and dates are in separated columns

how can i filter the adjacent hour of the max date ?

I hope I am clear enough 🙂

thanks !

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@GeekAlfPro , Try a new measure

 

new measure =
var _date =maxx(allselected(Table), Table[Date])
return
calculate(max(Table[Time]), filter(Table, Table[Date] =_date))

 

 

Or create a new column
datetime = [Date]+time

 

then use measure = maxx(allselected(Table), Table[Datetime])

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

@GeekAlfPro , Try a new measure

 

new measure =
var _date =maxx(allselected(Table), Table[Date])
return
calculate(max(Table[Time]), filter(Table, Table[Date] =_date))

 

 

Or create a new column
datetime = [Date]+time

 

then use measure = maxx(allselected(Table), Table[Datetime])

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

Hi @amitchandak,

 

it's perfect !

thanks a lot.

have a good day

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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