Piotr Jacek Puczynski wrote: > OK. > I also think the first option is better. However I don't know how to > force the model to join based on two columns in join table so that I > will be able to write simple 'user.friends' each time I need a friends' > list. Do you know how to hack it?
See the article I pointed to. You'll either need a union query or two joins to the same table. If you're going to do this, please make sure you understand the SQL involved. ActiveRecord exists to abstract, not to hide. > > Piotr J. Puczyński Best, -- Marnen Laibow-Koser http://www.marnen.org mar...@marnen.org -- 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-t...@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.