[Dbix-class] InflateColumn::DateTime - how to use it?

Tom Lanyon tom at netspot.com.au
Thu May 24 01:04:51 GMT 2007


On 24/05/2007, at 5:06 AM, Jason Kohles wrote:

> On May 17, 2007, at 8:21 AM, Jess Robinson wrote:
>
> Is the mailing list the appropriate way to get  
> InflateColumn::DateTime patched?  I put this simple little patch in  
> RT a while ago but it never seemed to get acted on, and it would be  
> nice if I didn't have to keep re-applying it every time I upgrade  :)
>
> Index: DateTime.pm
> ===================================================================
> --- DateTime.pm (revision 3369)
> +++ DateTime.pm (working copy)
> @@ -54,7 +54,7 @@
>    $self->next::method($column, $info, @rest);
>    return unless defined($info->{data_type});
>    my $type = lc($info->{data_type});
> -  $type = 'datetime' if ($type eq 'timestamp');
> +  $type = 'datetime' if ($type =~ /timestamp/);
>    if ($type eq 'datetime' || $type eq 'date') {
>      my ($parse, $format) = ("parse_${type}", "format_${type}");
>      $self->inflate_column(



Jason,

Just curious, what column type are you using that includes  
'timestamp' as well as other chars?

Tom



More information about the Dbix-class mailing list