New JSON theme available! Check it out here!
How can we help?

Welcome to Curbal Learning Portal. Search for answers using the search box below,
or create a request for a video or blog if you cannot find your answer.

Popular searches: DAX Glossary | Guided courses | Request a video

Print

Round time to nearest 15 min with Power Query

In today’s video I will show you how to round time to the nearest 15 minutes in Power Query, but of course, the same formula can be applied to other time intervals.

Rounding time can be needed if you want to group time in different buckets or bins for better visualization, but also if you have different time granularity in your data.
To round time in Power Query, you can use a similar formula that you would use in excel, but you need to convert it to Power Query formulas.

1. To round time to nearest 15 min in Excel you would use: CEILING(A1;1/96)
2. To round Down time to nearest 15 min in Power Query, you use: Time.From(Number.RoundDown(96*Number.From(Time.From([SubscriptionCreated]))/1)/96)) 96
will give you 15 min interval, if you need 10, 30 or one hour interval, just change the number and you are done.

Watch the tutorial:

Round time to nearest 15 min with Power Query

Links to the mentioned resources

Do you want to do it in DAX? No problem, here is how:

DAX Fridays! #31: Rounding Time, Prices and Numbers with DAX
Was this helpful?
Previous List dates between two dates in Power Query – Part 1
Next Convert Epoch/ Unix time to datetime in Power Query in one step

Reader Interactions

Let us know your thoughts...

Table of Contents