added datetime parser types for the dbs I can find them for
Matt S Trout [Sat, 20 May 2006 00:33:14 +0000 (00:33 +0000)]
lib/DBIx/Class/Storage/DBI/DB2.pm
lib/DBIx/Class/Storage/DBI/Pg.pm
t/lib/DBICTest/Schema/Event.pm

index 83e2bc7..8e867e0 100644 (file)
@@ -21,6 +21,8 @@ sub last_insert_id
                          
 }
 
+sub datetime_parser_type { "DateTime::Format::DB2"; }
+
 1;
 
 =head1 NAME
index 526abac..5940de2 100644 (file)
@@ -35,6 +35,8 @@ sub sqlt_type {
   return 'PostgreSQL';
 }
 
+sub datetime_parser_type { return "DateTime::Format::Pg"; }
+
 1;
 
 =head1 NAME
index 92dad5d..e9642e3 100644 (file)
@@ -2,15 +2,4 @@ package DBICTest::Schema::Event;
 
 use base qw/DBIx::Class/;
 
-__PACKAGE__->load_components(qw/InflateColumn::DateTime PK::Auto Core/);
-
-__PACKAGE__->table('event');
-
-__PACKAGE__->add_columns(
-  id => { data_type => 'integer', is_auto_increment => 1 },
-  starts_at => { data_type => 'datetime' }
-);
-
-__PACKAGE__->set_primary_key('id');
-
-1;
+__PACKAGE__->load_components(qw/