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

Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.

Reply
arsm
Frequent Visitor

How to combine Date Hour in power query

Hello, I'm new to power bi, how do i combine date and hour into column 

 

result im lookig from  2/15/2023 14:32:45  to  2/15/2023 14:0:0  i want to remove minutes and seconds and keep the format as date/time

 

Thank you

2 ACCEPTED SOLUTIONS
ronrsnfld
Super User
Super User

in Power BI, you can add a new column:

 

 

Date-hr = Time(hour([Column1]),0,0) + Int([Column1])

 

 

 

View solution in original post

collinsg
Super User
Super User

Good day arsm,

Power Query provides a function Time.StartOfHour, for example if your datetime column is called "DateTime" and your previous steps is called "Previous Step", this code will transform the column to give the start of the hour and retain the type as datetime.

= Table.TransformColumns(#"Previous Step",{{"DateTime", Time.StartOfHour, type datetime}})

This transformation is available via the GUI on the "Transform" tab, "Date & Time Column" area and "Time", "Hour", "Start of Hour".

Hope this helps

View solution in original post

4 REPLIES 4
collinsg
Super User
Super User

Good day arsm,

Power Query provides a function Time.StartOfHour, for example if your datetime column is called "DateTime" and your previous steps is called "Previous Step", this code will transform the column to give the start of the hour and retain the type as datetime.

= Table.TransformColumns(#"Previous Step",{{"DateTime", Time.StartOfHour, type datetime}})

This transformation is available via the GUI on the "Transform" tab, "Date & Time Column" area and "Time", "Hour", "Start of Hour".

Hope this helps

arsm
Frequent Visitor

Thank you collinsg

ronrsnfld
Super User
Super User

in Power BI, you can add a new column:

 

 

Date-hr = Time(hour([Column1]),0,0) + Int([Column1])

 

 

 

Thank you ronrsnfld 

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.

Top Kudoed Authors