I have a datetime colum and I can easily run queries with a group by on my datetime column. However, I would like to run group queries for minute intervals, two minute intervals, 5 minute intervals, hour intervals etc. How do I do this? Thanks.