The hacker_news question has one about what is the best time to post. The solution I have is the following:
SELECT TIME(timestamp), COUNT(*)
FROM hacker_news
WHERE TIME(timestamp) NOT NULL
GROUP BY 1
ORDER BY 2;
When I run this I get:
TIME(timestamp) | COUNT(*) |
---|---|
19:44:20 | 3 |
18:00:05 | 3 |
17:09:45 | 3 |
23:59:19 | 2 |
and so on…
So, if i am right, we have a three-way tie. 3 times each for the time periods: 19:44:20, 18:00:25 and 17:09:44.
- Note I am using the TIME () function which translates the YYYY-MM-DD HH:MM:SS to HH:MM:SS.
Is this what they wanted? Not sure.