All of the interesting technological, artistic or just plain fun subjects I'd investigate if I had an infinite number of lifetimes. In other words, a dumping ground...

Saturday 29 December 2007

Postgresql - Counting Sundays

http://www.depesz.com/index.php/2007/12/27/how-many-1sts-of-any-month-were-sundays-since-1901-01-01/

how many 1sts of any month were sundays - since 1901-01-01?

December 27th, 2007 by depesz

nixternal wrote about boost library for c++.

with it he was able to find the answer to title question in miliseconds (he didn't specify how many, but let's assume that is was less than 10 ms).

so i decided to check how fast can i do it in postgresql …


No comments:

tim's shared items

Add to Google Reader or Homepage