MySQL sum each X rows
|Added at||2017-01-04 14:01|
I need little MySQL help. I have a table with hourly values like that:
Now I have found that sometimes the data which i get is not on hourly bases but it is for every 30 Minutes or sometimes for every 15 Minutes. So the data can look like this:
I need to display the data in hourly format, so I am curious if there is any chance to tell MySQL to sum each two (for 30 Minutes format) or each four (15 Minutes format) rows of the result ?