[Dbix-class] DBIx::Class::ResultSet (paging <-> slicing) proposed patch

James Kiser james.kiser at gmail.com
Fri Dec 7 23:15:01 GMT 2007


I came across an issue when trying to slice a paged result set.
Basically, it boils down to the offset not being calculated properly
when slicing a paged result set.

I wrote a patch (diff: http://scsys.co.uk:8001/11287) that corrects
this issue and have tested the following (order of operation is right
to left):

+ sliced result set
+ paged result set
+ paged, paged result set
+ sliced, paged result set
+ paged, sliced result set
+ sliced, paged, sliced result set
+ sliced, sliced, paged, sliced result set
+ paged, paged, sliced result set
+ sliced, paged, paged, sliced result set
+ paged, sliced, paged, paged, sliced result set

I plan on writing automated tests but wanted to get feedback/approval
from the list before moving forward.

Thanks,
James



More information about the DBIx-Class mailing list