It's worth noting that this particular dataset easily fits into memory. I had done a similar analysis 9 months ago on the same dataset (blog post: http://minimaxir.com/2015/12/sf-arrests/ , Jupyter notebook: https://github.com/minimaxir/sf-arrests-when-where/blob/mast...) and it is 377.9 MB on disk, 180.9 MB in memory.
Using a SQL approach for that amount of data instead of manipulating the data via R/Python may be overkill and unnecessarily verbose. (e.g. date/time conversions and catching edge cases like Feb 29)