Give a child a spoon and...

...they will entertain themselves for many precious minutes...

Katja and a spoon
Katja and a spoon

Summer has arrived - finally!

This weekend marked the first consistent period of above 22C temperatures and sunshine. Truly remarkable... We had winter up to end of May.

This car will be my undoing

At $1.50 per litre for petrol at the moment in Canada for 91 octane, and at these consumption rates, I am in for a bitter sweet period... This was after about 150km of driving in the city...

21l/100km
21l/100km

HTTPS (SSL) Support in Perl's LWP::Simple

If you run Ubuntu Linux and using Perl's LWP::Simple's get function to fetch the content of an SSL encrypted web site, make sure to install libcrypt-ssleay-perl to enable SSL support for LWP.

Conditional inserts in PostgreSQL

I have many times wanted to perform the following kind of SQL statement:

insert into X (field1, field2) values (A,B) if not exists X.field1 = A

The idea is to have a single statement that only inserts the value if a given key (in this case A) does not already exist. Therefore it is like a unique add operation. To implement this in PostgreSQL, simply do:

Full Article