Daily Aggregation and Filtering

Aggregate the table with time range filtering, with daily groupings.

Description

This example shows how to apply daily aggregation and filtering. The queries below are applying the aggregate functions, to the last 7 days worth of data.

Sample Input

tbl
time col
1416435585 2
1416435586 3
1416435587 5
1416435588 1
... ...

Query


to view this query

Sample Output

day cnt sum
2014-10-01 31 300
2014-10-02 33 130
2014-10-03 13 333
2014-10-04 23 345
2014-10-05 91 390
2014-10-06 13 103
2014-10-07 42 329