Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
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
Solved! Go to Solution.
in Power BI, you can add a new column:
Date-hr = Time(hour([Column1]),0,0) + Int([Column1])
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
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
Thank you collinsg
in Power BI, you can add a new column:
Date-hr = Time(hour([Column1]),0,0) + Int([Column1])
Thank you ronrsnfld
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.