Bucketizing date and time data
SQL Performance
AUGUST 11, 2021
One is using a function called DATE_BUCKET , which at the time of writing is only available in Azure SQL Edge. Another is using a custom calculation that emulates the DATE_BUCKET function, which you can use in any version, edition, and flavor of SQL Server and Azure SQL Database. In my examples, I’ll use the sample database TSQLV5.
Let's personalize your content