My table stores the Unix timestamp of each forum post. I want to be able to graph [number of posts in this day] VS [days since epoch]. My first step was to be able to detect which posts were from the same day:
SELECT ROUND(time / 86400) as daysSinceEpoch, time
FROM posts
ORDER BY daysSinceEpoch
ASC
This gives me:
daysEpoch time
13378 1155850620
13378 1155850620
13378 1155850920
13378 1155851040
13378 1155851160
13386 1156568400
13387 1156629120
13387 1156629180
13387 1156629180
Now I don’t know how to complete the query to give me:
daysEpoch numPostsInThisDay
13378 5
13386 1
13387 3