i''ve read that acts as ferret could be faster than mysql for full text search with many rows. but is still an option acts as ferret if my search (besides full text search in 2 or 3 columns) also includes pagination, sorting result, other conditions (e.g. price > min and price < max, created_at last week, user_type = admin, show 2nd page, sort desc by price) ? or if my search contains other conditions besides full text search i should use mysql? 10x -- 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
if you''ve got massive amounts of data and need fast search results then ferret and acts_as_ferret are definitly an option. It fits all of your needs - range queries, sorting etc. if things are performant on mysql and you are able to rely on myisam instead of innodb (on which there is no fulltext ability) then you are fine with mysql standalone. Cheers, Jan --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
http://blog.zmok.net/articles/2006/08/14/full-text-search-in-ruby-on-rails --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
On Oct 26, 2006, at 8:25 AM, Jan Prill wrote:> if you''ve got massive amounts of data and need fast search results > then ferret and acts_as_ferret are definitly an option. It fits all > of your needs - range queries, sorting etc. > > if things are performant on mysql and you are able to rely on > myisam instead of innodb (on which there is no fulltext ability) > then you are fine with mysql standalone.Is there a way to do simple joins in ferret, like "search ''foo'' in the posts written by user wth ID 37" or "serach ''foo'' in the posts written by users who are administrators" ? --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
On 10/26/06, Xavier Noria <fxn-xlncskNFVEJBDgjK7y7TUQ@public.gmane.org> wrote:> > On Oct 26, 2006, at 8:25 AM, Jan Prill wrote: > > > if you''ve got massive amounts of data and need fast search results > > then ferret and acts_as_ferret are definitly an option. It fits all > > of your needs - range queries, sorting etc. > > > > if things are performant on mysql and you are able to rely on > > myisam instead of innodb (on which there is no fulltext ability) > > then you are fine with mysql standalone. > > Is there a way to do simple joins in ferret, like > > "search ''foo'' in the posts written by user wth ID 37" > > or > > "serach ''foo'' in the posts written by users who are administrators" > > ?Hi Xavier, This is kind of possible but you have to remember that Ferret is not a database (yet) so things work a little differently. Ferret is basically a large array of *documents*, which are basically Hashes of text fields. All fields are stored as text (although you can sort results by integer fields and do range queries on integers). So if you want to do queries like those specified above you need to put all the values you need into a single document. So for your first example:> "search ''foo'' in the posts written by user wth ID 37"You need to store the user ID in the document along with the post. If there are multiple user IDs per post then you can store an array of ids. Your query would then look like this: "post:foo user_id:37" Your second example would look like this: "post:foo user_role:administrator" and you would need to store the user_role in the document as well. I hope this makes sense. I''m currently in the initial stages of building an object database based on Ferret so eventually you''ll be able to do joins[1] and all those other good things you can do in databases and maybe even do away with your current database. Cheers, Dave [1] well, technically in an object database they are not really joins but nevermind. -- Dave Balmain http://www.davebalmain.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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---