first you must test if the relation by name is collection, then you must either get the relation using accessor, or get the collection using reflection from metadata