riak-ripple / ripple

A rich Ruby modeling layer for Riak, Basho's distributed database
Other
619 stars 152 forks source link

How to find record in many association? #319

Open sharp opened 11 years ago

sharp commented 11 years ago

There is one model

class Person
  include Ripple::Document
  property :name, String
  many :addresses
  many :friends, :class_name => "Person"
  one :account
end

If there are two person model instances, how to find one person is in the other's friends ? There is no document description