July 2009 Archives

DBIC note to self...

|
Update 2010-03-10: The bug this works around has been fixed as of DBIx-Class-0.08120 (released 2010-02-24), so it is no longer necessary to use this hack unless you are stuck with an old DBIx::Class.

There's an interesting interaction between PostgreSQL, DBIx::Class::Schema::Loader and DBIx::Class:InflateColumn::DateTime.

When you define a column to be of type TIMESTAMP, it actually becomes a TIMESTAMP WITHOUT TIME ZONE. DBIx::Class::Schema::Loader just copies this into the DBIC data_type field without translation, and so when DBIx::Class::InflateColumn::DateTime comes along, it doesn't realise it's a time value and doesn't bother to add the inflater.

This awful kludge hooks register_column and changes the data_type field to "timestamp", thus making it all work as expected.

(code after the cut)

Geekcycle, part 3

|
Spring-cleaning 2009--shush, I know it's summer--and it's time to dispose of more tat. Today's unwanted item is a Sherwood DD-1030 double tape deck, and fifty-odd tapes. Relive the era before MP3s with wow, flutter and dr-pou-s.

The binmen come on Monday, so it'll need claming before then.


About this Archive

This page is an archive of entries from July 2009 listed from newest to oldest.

September 2008 is the previous archive.

Find recent content on the main index or look in the archives to find all content.