X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FDBIx%2FClass%2FStorage%2FDBI%2FSybase%2FMicrosoft_SQL_Server.pm;h=22661a85d2104570d7facf81cda52428d3d13058;hb=322b7a6b;hp=e7f0e512df6215bf3d2d586b5fc9f0b76f596a8e;hpb=51ac7136944f82aa2675cc133a8d080c5fb367b1;p=dbsrgits%2FDBIx-Class.git diff --git a/lib/DBIx/Class/Storage/DBI/Sybase/Microsoft_SQL_Server.pm b/lib/DBIx/Class/Storage/DBI/Sybase/Microsoft_SQL_Server.pm index e7f0e51..22661a8 100644 --- a/lib/DBIx/Class/Storage/DBI/Sybase/Microsoft_SQL_Server.pm +++ b/lib/DBIx/Class/Storage/DBI/Sybase/Microsoft_SQL_Server.pm @@ -9,6 +9,12 @@ use base qw/ /; use mro 'c3'; +sub new { + my $self = shift->next::method(@_); + $self->_rebless; + return $self; +} + sub _rebless { my $self = shift; my $dbh = $self->_get_dbh; @@ -21,11 +27,8 @@ sub _rebless { # LongReadLen doesn't work with MSSQL through DBD::Sybase, and the default is # huge on some versions of SQL server and can cause memory problems, so we -# fix it up here. - my $text_size = eval { $self->_dbi_connect_info->[-1]->{LongReadLen} } || - 32768; # the DBD::Sybase default - - $dbh->do("set textsize $text_size"); +# fix it up here (see Sybase/Common.pm .) + $self->set_textsize; } 1;