On Oct 20, 9:26 am, Nate Wiger <[email protected]> wrote: > How do I do a find by primary key thru the association?
Jeremy possibly has a better answer, but I would do: game = Game[5] game.game_players_dataset.filter(:id=>17).first However, if you have the PK already, why not just: bob = GamePlayer[17] Are you trying to see if a player with a particular ID is in the association? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sequel-talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/sequel-talk?hl=en -~----------~----~----~----~------~----~------~--~---
