On 4 February 2010 00:01, James Marca <[email protected]> wrote: > On Wed, Feb 03, 2010 at 11:14:28PM +0100, demerphq wrote: >> Ive implemented this type of thing outside of DBIx by limiting the >> query to one more record than I intend to page. >> >> This works nicely as it does two things. First it gives me a flag >> which i can use to decide whether a page need a "show next page link", >> and it gives me an item that i can use to prekey the paging so it does >> NOT use the offset/limit form, and instead uses the id of the flag >> record to do an indexed search from where the next page starts. >> > > Ah, very clever hack!
Its pretty easy to do with one way paging, a bit harder with bi-directional paging. But still not too hard. Yves -- perl -Mre=debug -e "/just|another|perl|hacker/" _______________________________________________ List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class IRC: irc.perl.org#dbix-class SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/ Searchable Archive: http://www.grokbase.com/group/[email protected]
