2009/5/30 Maurício Linhares <mauricio.linha...@gmail.com> > > Have you tried to add a :limit clause to your select statement? > > Maybe show only the first 15 results and make sure there's an index at > the column being searched for. > > - > Maurício Linhares > http://alinhavado.wordpress.com/ (pt-br) | http://blog.codevader.com/ (en) > > > > On Sat, May 30, 2009 at 3:08 PM, Me <chabg...@gmail.com> wrote: > > > > Is there anything I can do to speed up the query of a table that has > > 380,000 entries and will only get bigger? > > > > I tried the recipe in the rails recipe book but the page takes a long > > time just for the page to load due to the array being generated. > > > > > >
Also, you may also try using the :select to limit what fields you fetch from your database. If you can provide a sample code, we can better assist you. Other than that, I would recommend using the #{RAILS_ROOT}/script/performance/benchmarker to profile your queries to make sure that your optimizations are truly working for the query in question. Good luck, -Conrad > > > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---