I want to link up 3 tables to list all members of a particular group. My code (which is wrong) looks like this:
@group_members = Membership.find( :all, :joins => ['FROM memberships INNER JOIN groups ON memberships.group_id= group.id' + 'INNER JOIN users ON memberships.user_id=users.id']) This gives me an "association name not found" error. From my log file the sql string is as follows: 'FROM memberships INNER JOIN groups ON memberships.group_id= group.idINNER JOIN users ON memberships.user_id=users.id' Can anyone please let me know where I'm going wrong - SQL is not my forté :@/ Thanks Steve -- 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 -~----------~----~----~----~------~----~------~--~---