in reply to fetchall_arrayref with slice and row count

I found the same thing to be true in DBI::fetchall_arrayref() error. I guess you could say that the general consensus was that it was a bug. I think it would be nice to have the best of both worlds (slice + limit).

blokhead

  • Comment on Re: fetchall_arrayref with slice and row count

Replies are listed 'Best First'.
Re^2: fetchall_arrayref with slice and row count
by druud (Sexton) on Nov 28, 2009 at 17:11 UTC
    Not a bug. So wrong usage.
    while ( $sth->{Active} and $rowcache=$sth->fetchall_arrayref({}, $max_rows) ) { ... }
    See the DBI documentation: the last possible fetch in a fetchall will call $sth->finish.