X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FDBIx%2FClass%2FStorage%2FDBI%2FCursor.pm;h=3d59e84a04bd6b522de93e4d46cf86007f52d069;hb=d3944540917a76cd054d1bf4ed98f2571c077b2d;hp=bd2a20a7005906c25d5b17600b0082e798f3cedb;hpb=47614763f0a3e390d6caea0be8e1bbee00198c49;p=dbsrgits%2FDBIx-Class-Historic.git diff --git a/lib/DBIx/Class/Storage/DBI/Cursor.pm b/lib/DBIx/Class/Storage/DBI/Cursor.pm index bd2a20a..3d59e84 100644 --- a/lib/DBIx/Class/Storage/DBI/Cursor.pm +++ b/lib/DBIx/Class/Storage/DBI/Cursor.pm @@ -1,10 +1,10 @@ package DBIx::Class::Storage::DBI::Cursor; -use base qw/DBIx::Class::Cursor/; - use strict; use warnings; +use base qw/DBIx::Class::Cursor/; + =head1 NAME DBIx::Class::Storage::DBI::Cursor - Object representing a query cursor on a @@ -68,7 +68,11 @@ sub _dbh_next { my ($storage, $dbh, $self) = @_; $self->_check_dbh_gen; - if ($self->{attrs}{rows} && $self->{pos} >= $self->{attrs}{rows}) { + if ( + $self->{attrs}{software_limit} + && $self->{attrs}{rows} + && $self->{pos} >= $self->{attrs}{rows} + ) { $self->{sth}->finish if $self->{sth}->{Active}; delete $self->{sth}; $self->{done} = 1; @@ -128,6 +132,7 @@ sub all { && ($self->{attrs}{offset} || $self->{attrs}{rows})) { return $self->next::method; } + $self->{storage}->dbh_do($self->can('_dbh_all'), $self); }