Brian Durand
2009-Mar-05 17:57 UTC
[PATCH] Allow find_in_batches to use :order, :limit, and :offset
Created patch which allows find_batches to use :order, :limit, and :offset for better control over batch processing. Also supports models which don''t use integer primary keys. http://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/2137-allow-find_batches-to-use-order-limit-and-offset#ticket-2137-2 --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en -~----------~----~----~----~------~----~------~--~---
Mislav Marohnić
2009-Mar-06 01:24 UTC
Re: [PATCH] Allow find_in_batches to use :order, :limit, and :offset
On Thu, Mar 5, 2009 at 18:57, Brian Durand <brian@embellishedvisions.com>wrote:> > Created patch which allows find_batches to use :order, :limit, > and :offset for better control over batch processing.See my reply on the main thread about why giving such options might not be a good idea. Anyway, the will_paginate plugin provides the `paginated_each` class method on models which lets you iterate with :order and :per_page parameters. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en -~----------~----~----~----~------~----~------~--~---