Hi, I'm using paginate_by_sql to have pagination for my list views as my queries have joins on multiple tables. I have included the code into my application.rb , and in the controller I have:
@discipline_pages, @disciplines = paginate_by_sql(Discipline,query,2) But I get error as: wrong number of arguments (4 for 2) app/controllers/application.rb:63:in `initialize' app/controllers/application.rb:63:in `new' app/controllers/application.rb:63:in `paginate_by_sql' app/controllers/discipline_controller.rb:140:in `list' At application.rb:63 I have: object_pages = Paginator.new self, total, per_page,params['page'] Please can someone help me with this... Thanks in advance. -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---