X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FDBIx%2FClass%2FStorage%2FDBI%2FSQLAnywhere.pm;h=9cb8306637c3c6e1b8197752a4520d2845fc3d25;hb=616ca57f8cd27f475da275bbef986fdd42d4069f;hp=57687ad6ac6fdb008e8ede42878fadc0419bc20f;hpb=87b1255103d7b8873b225416cb381c50011f4c06;p=dbsrgits%2FDBIx-Class.git diff --git a/lib/DBIx/Class/Storage/DBI/SQLAnywhere.pm b/lib/DBIx/Class/Storage/DBI/SQLAnywhere.pm index 57687ad..9cb8306 100644 --- a/lib/DBIx/Class/Storage/DBI/SQLAnywhere.pm +++ b/lib/DBIx/Class/Storage/DBI/SQLAnywhere.pm @@ -5,7 +5,7 @@ use warnings; use base qw/DBIx::Class::Storage::DBI::UniqueIdentifier/; use mro 'c3'; use DBIx::Class::_Util 'dbic_internal_try'; -use Try::Tiny; +use DBIx::Class::ResultSource::FromSpec::Util 'fromspec_columns_info'; use namespace::clean; __PACKAGE__->mk_group_accessors(simple => qw/_identity/); @@ -113,7 +113,7 @@ sub select_single { my ($ident, $select) = @_; - my $col_info = $self->_resolve_column_info($ident); + my $col_info = fromspec_columns_info($ident); for my $select_idx (0..$#$select) { my $selected = $select->[$select_idx]; @@ -135,18 +135,11 @@ sub select_single { return @row; } -# this sub stolen from MSSQL - sub build_datetime_parser { - my $self = shift; - dbic_internal_try { - require DateTime::Format::Strptime; - } - catch { - $self->throw_exception("Couldn't load DateTime::Format::Strptime: $_"); - }; - return DateTime::Format::Strptime->new( pattern => '%Y-%m-%d %H:%M:%S.%6N' ); + require DateTime::Format::Strptime; + + DateTime::Format::Strptime->new( pattern => '%Y-%m-%d %H:%M:%S.%6N' ); } =head2 connect_call_datetime_setup